Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1125)

Unified Diff: storage/browser/blob/blob_url_request_job.cc

Issue 2346623002: [BlobStorage] Adding error code translations for cache storage metadata. (Closed)
Patch Set: One more error code Created 4 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: storage/browser/blob/blob_url_request_job.cc
diff --git a/storage/browser/blob/blob_url_request_job.cc b/storage/browser/blob/blob_url_request_job.cc
index 24882d5e2c9d6a6581ad8e8375e4ceb04bfda72a..aa06ea2cc8a6ba0f0099fb2c30b23ac7290b11ee 100644
--- a/storage/browser/blob/blob_url_request_job.cc
+++ b/storage/browser/blob/blob_url_request_job.cc
@@ -253,6 +253,8 @@ void BlobURLRequestJob::NotifyFailure(int error_code) {
status_code = net::HTTP_FORBIDDEN;
break;
case net::ERR_FILE_NOT_FOUND:
+ case net::ERR_CACHE_READ_FAILURE:
+ case net::ERR_CACHE_CHECKSUM_READ_FAILURE:
jsbell 2016/09/14 22:03:13 Maybe this (these?) should be HTTP_INTERNAL_SERVER
dmurph 2016/09/14 22:07:19 Sure, not really picky here, just don't want to DC
status_code = net::HTTP_NOT_FOUND;
break;
case net::ERR_METHOD_NOT_SUPPORTED:
@@ -261,10 +263,14 @@ void BlobURLRequestJob::NotifyFailure(int error_code) {
case net::ERR_REQUEST_RANGE_NOT_SATISFIABLE:
status_code = net::HTTP_REQUESTED_RANGE_NOT_SATISFIABLE;
break;
+ case net::ERR_INVALID_ARGUMENT:
+ status_code = net::HTTP_BAD_REQUEST;
+ break;
+ case net::ERR_UNEXPECTED:
case net::ERR_FAILED:
break;
default:
- DCHECK(false);
+ DCHECK(false) << "Error code not supported: " << error_code;
break;
}
HeadersCompleted(status_code);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698