| Index: storage/browser/blob/blob_reader.cc
|
| diff --git a/storage/browser/blob/blob_reader.cc b/storage/browser/blob/blob_reader.cc
|
| index 2eafdbcc77e6fcdbc8e4ef1d00248d3f5db4f22e..0fae3f21ac2a14ed0e144ee37918ae9f174a52f0 100644
|
| --- a/storage/browser/blob/blob_reader.cc
|
| +++ b/storage/browser/blob/blob_reader.cc
|
| @@ -84,9 +84,11 @@ BlobReader::Status BlobReader::CalculateSize(
|
| DCHECK(!total_size_calculated_);
|
| DCHECK(size_callback_.is_null());
|
| if (!blob_handle_.get() || blob_handle_->IsBroken()) {
|
| + LOG(ERROR) << "Broken blob, or non existant";
|
| return ReportError(net::ERR_FILE_NOT_FOUND);
|
| }
|
| if (blob_handle_->IsBeingBuilt()) {
|
| + LOG(ERROR) << blob_handle_->uuid() << " blob still being built";
|
| blob_handle_->RunOnConstructionComplete(base::Bind(
|
| &BlobReader::AsyncCalculateSize, weak_factory_.GetWeakPtr(), done));
|
| return Status::IO_PENDING;
|
| @@ -248,6 +250,7 @@ void BlobReader::InvalidateCallbacksAndDone(int net_error,
|
| }
|
|
|
| BlobReader::Status BlobReader::ReportError(int net_error) {
|
| + LOG(ERROR) << "Reporting error << " << net_error;
|
| net_error_ = net_error;
|
| return Status::NET_ERROR;
|
| }
|
| @@ -256,9 +259,11 @@ void BlobReader::AsyncCalculateSize(const net::CompletionCallback& done,
|
| bool async_succeeded,
|
| IPCBlobCreationCancelCode reason) {
|
| if (!async_succeeded) {
|
| + LOG(ERROR) << "Blob construction failed";
|
| InvalidateCallbacksAndDone(ConvertBlobErrorToNetError(reason), done);
|
| return;
|
| }
|
| + LOG(ERROR) << blob_handle_->uuid() << " consruction done";
|
| DCHECK(!blob_handle_->IsBroken()) << "Callback should have returned false.";
|
| blob_data_ = blob_handle_->CreateSnapshot();
|
| Status size_status = CalculateSizeImpl(done);
|
|
|