| Index: storage/browser/blob/blob_url_request_job_factory.cc
|
| diff --git a/storage/browser/blob/blob_url_request_job_factory.cc b/storage/browser/blob/blob_url_request_job_factory.cc
|
| index feb5df0855ca50dad00c039a049f28b3b9632f84..170f23152e86128066cc6a49fba421799fe2de3f 100644
|
| --- a/storage/browser/blob/blob_url_request_job_factory.cc
|
| +++ b/storage/browser/blob/blob_url_request_job_factory.cc
|
| @@ -59,18 +59,16 @@ BlobProtocolHandler::~BlobProtocolHandler() {
|
|
|
| net::URLRequestJob* BlobProtocolHandler::MaybeCreateJob(
|
| net::URLRequest* request, net::NetworkDelegate* network_delegate) const {
|
| - return new storage::BlobURLRequestJob(request,
|
| - network_delegate,
|
| - LookupBlobData(request),
|
| - file_system_context_.get(),
|
| - file_task_runner_.get());
|
| + return new storage::BlobURLRequestJob(
|
| + request, network_delegate, LookupBlobHandle(request),
|
| + file_system_context_.get(), file_task_runner_.get());
|
| }
|
|
|
| -scoped_ptr<BlobDataSnapshot> BlobProtocolHandler::LookupBlobData(
|
| +BlobDataHandle* BlobProtocolHandler::LookupBlobHandle(
|
| net::URLRequest* request) const {
|
| BlobDataHandle* blob_data_handle = GetRequestedBlobDataHandle(request);
|
| if (blob_data_handle)
|
| - return blob_data_handle->CreateSnapshot().Pass();
|
| + return blob_data_handle;
|
| if (!context_.get())
|
| return NULL;
|
|
|
| @@ -83,12 +81,11 @@ scoped_ptr<BlobDataSnapshot> BlobProtocolHandler::LookupBlobData(
|
| return NULL;
|
| std::string uuid = request->url().spec().substr(kPrefix.length());
|
| scoped_ptr<BlobDataHandle> handle = context_->GetBlobDataFromUUID(uuid);
|
| - scoped_ptr<BlobDataSnapshot> snapshot;
|
| + BlobDataHandle* handle_ptr = handle.get();
|
| if (handle) {
|
| - snapshot = handle->CreateSnapshot().Pass();
|
| SetRequestedBlobDataHandle(request, handle.Pass());
|
| }
|
| - return snapshot.Pass();
|
| + return handle_ptr;
|
| }
|
|
|
| } // namespace storage
|
|
|