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

Unified Diff: chrome/renderer/security_filter_peer.cc

Issue 10640019: Remove the HANDLED_EXTERNALLY status code. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: rebase + fix nits Created 8 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 | « chrome/renderer/security_filter_peer.h ('k') | content/browser/renderer_host/async_resource_handler.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/security_filter_peer.cc
diff --git a/chrome/renderer/security_filter_peer.cc b/chrome/renderer/security_filter_peer.cc
index ee05496fea5b5fdc99665cd335aa73971fd6e693..c72015678663e00c997dff3e765b968c7cfcdb8b 100644
--- a/chrome/renderer/security_filter_peer.cc
+++ b/chrome/renderer/security_filter_peer.cc
@@ -90,7 +90,8 @@ void SecurityFilterPeer::OnReceivedData(const char* data,
}
void SecurityFilterPeer::OnCompletedRequest(
- const net::URLRequestStatus& status,
+ int error_code,
+ bool was_ignored_by_handler,
const std::string& security_info,
const base::TimeTicks& completion_time) {
NOTREACHED();
@@ -150,19 +151,19 @@ void BufferedPeer::OnReceivedData(const char* data,
data_.append(data, data_length);
}
-void BufferedPeer::OnCompletedRequest(const net::URLRequestStatus& status,
+void BufferedPeer::OnCompletedRequest(int error_code,
+ bool was_ignored_by_handler,
const std::string& security_info,
const base::TimeTicks& completion_time) {
// Make sure we delete ourselves at the end of this call.
scoped_ptr<BufferedPeer> this_deleter(this);
// Give sub-classes a chance at altering the data.
- if (status.status() != net::URLRequestStatus::SUCCESS || !DataReady()) {
+ if (error_code != net::OK || !DataReady()) {
// Pretend we failed to load the resource.
original_peer_->OnReceivedResponse(response_info_);
- net::URLRequestStatus status(net::URLRequestStatus::CANCELED,
- net::ERR_ABORTED);
- original_peer_->OnCompletedRequest(status, security_info, completion_time);
+ original_peer_->OnCompletedRequest(net::ERR_ABORTED, false, security_info,
+ completion_time);
return;
}
@@ -171,7 +172,8 @@ void BufferedPeer::OnCompletedRequest(const net::URLRequestStatus& status,
original_peer_->OnReceivedData(data_.data(),
static_cast<int>(data_.size()),
-1);
- original_peer_->OnCompletedRequest(status, security_info, completion_time);
+ original_peer_->OnCompletedRequest(error_code, was_ignored_by_handler,
+ security_info, completion_time);
}
////////////////////////////////////////////////////////////////////////////////
@@ -202,7 +204,8 @@ void ReplaceContentPeer::OnReceivedData(const char* data,
}
void ReplaceContentPeer::OnCompletedRequest(
- const net::URLRequestStatus& status,
+ int error_code,
+ bool was_ignored_by_handler,
const std::string& security_info,
const base::TimeTicks& completion_time) {
webkit_glue::ResourceResponseInfo info;
@@ -214,7 +217,8 @@ void ReplaceContentPeer::OnCompletedRequest(
original_peer_->OnReceivedData(data_.data(),
static_cast<int>(data_.size()),
-1);
- original_peer_->OnCompletedRequest(net::URLRequestStatus(),
+ original_peer_->OnCompletedRequest(net::OK,
+ false,
security_info,
completion_time);
« no previous file with comments | « chrome/renderer/security_filter_peer.h ('k') | content/browser/renderer_host/async_resource_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698