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

Unified Diff: webkit/glue/weburlloader_impl.cc

Issue 6328010: Fix Task Manager to correctly display network usage of plug-in processes. (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Redo patch set for changes to trunk. Created 9 years, 11 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/common/resource_dispatcher.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/weburlloader_impl.cc
diff --git a/webkit/glue/weburlloader_impl.cc b/webkit/glue/weburlloader_impl.cc
index 89044573f3d813e3c0894687a9e488a64f13868b..d4b51621e161f98252c844ee3ba2db95c670fa17 100644
--- a/webkit/glue/weburlloader_impl.cc
+++ b/webkit/glue/weburlloader_impl.cc
@@ -403,12 +403,6 @@ void WebURLLoaderImpl::Context::Start(
if (!request.allowStoredCredentials())
load_flags |= net::LOAD_DO_NOT_SEND_AUTH_DATA;
- // TODO(jcampan): in the non out-of-process plugin case the request does not
- // have a requestor_pid. Find a better place to set this.
- int requestor_pid = request.requestorProcessID();
- if (requestor_pid == 0)
- requestor_pid = base::GetCurrentProcId();
-
HeaderFlattener flattener(load_flags);
request.visitHTTPHeaderFields(&flattener);
@@ -429,7 +423,10 @@ void WebURLLoaderImpl::Context::Start(
request_info.main_frame_origin = main_frame_origin;
request_info.headers = flattener.GetBuffer();
request_info.load_flags = load_flags;
- request_info.requestor_pid = requestor_pid;
+ // requestor_pid only needs to be non-zero if the request originates outside
+ // the render process, so we can use requestorProcessID even for requests
+ // from in-process plugins.
+ request_info.requestor_pid = request.requestorProcessID();
request_info.request_type = FromTargetType(request.targetType());
request_info.appcache_host_id = request.appCacheHostID();
request_info.routing_id = request.requestorID();
« no previous file with comments | « chrome/common/resource_dispatcher.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698