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

Unified Diff: net/url_request/url_request.cc

Issue 10837123: Add histograms to NetworkChangeNotifier to identify ways to improve interface (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Register HistogramWatcher Observers on I/O thread. Rename Net.NCN to NCN. Created 8 years, 4 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
« net/base/network_change_notifier.cc ('K') | « net/base/network_change_notifier.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/url_request/url_request.cc
diff --git a/net/url_request/url_request.cc b/net/url_request/url_request.cc
index 8ea6325d819e072b5ad455b4c68867c90b7fa131..50c728e5caf00cba02eb40b900719453b78abbb1 100644
--- a/net/url_request/url_request.cc
+++ b/net/url_request/url_request.cc
@@ -20,6 +20,7 @@
#include "net/base/load_flags.h"
#include "net/base/net_errors.h"
#include "net/base/net_log.h"
+#include "net/base/network_change_notifier.h"
#include "net/base/network_delegate.h"
#include "net/base/ssl_cert_request_info.h"
#include "net/base/upload_data.h"
@@ -879,6 +880,9 @@ void URLRequest::NotifyReadCompleted(int bytes_read) {
if (bytes_read <= 0)
NotifyRequestCompleted();
+ // Notify NetworkChangeNotifier that we just received network data
szym 2012/08/08 20:41:17 nit: add '.' at end of sentence. Perhaps explain t
pauljensen 2012/08/13 15:42:04 Done.
+ NetworkChangeNotifier::NotifyDataReceived(url());
+
if (delegate_)
delegate_->OnReadCompleted(this, bytes_read);
« net/base/network_change_notifier.cc ('K') | « net/base/network_change_notifier.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698