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

Unified Diff: net/udp/udp_socket_win.cc

Issue 734063004: Update from https://crrev.com/304418 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 | « net/udp/udp_socket_libevent.cc ('k') | net/url_request/sdch_dictionary_fetcher.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/udp/udp_socket_win.cc
diff --git a/net/udp/udp_socket_win.cc b/net/udp/udp_socket_win.cc
index 4c307fd3b2804f4cec8fcf370aafc875050150a3..11c731f01d390ac6f399de2d8e7c39467f09e640 100644
--- a/net/udp/udp_socket_win.cc
+++ b/net/udp/udp_socket_win.cc
@@ -20,6 +20,7 @@
#include "net/base/net_errors.h"
#include "net/base/net_log.h"
#include "net/base/net_util.h"
+#include "net/base/network_activity_monitor.h"
#include "net/base/winsock_init.h"
#include "net/base/winsock_util.h"
#include "net/socket/socket_descriptor.h"
@@ -595,6 +596,7 @@ void UDPSocketWin::LogRead(int result, const char* bytes) const {
base::StatsCounter read_bytes("udp.read_bytes");
read_bytes.Add(result);
+ NetworkActivityMonitor::GetInstance()->IncrementBytesReceived(result);
}
void UDPSocketWin::DidCompleteWrite() {
@@ -626,6 +628,7 @@ void UDPSocketWin::LogWrite(int result,
base::StatsCounter write_bytes("udp.write_bytes");
write_bytes.Add(result);
+ NetworkActivityMonitor::GetInstance()->IncrementBytesSent(result);
}
int UDPSocketWin::InternalRecvFrom(IOBuffer* buf, int buf_len,
« no previous file with comments | « net/udp/udp_socket_libevent.cc ('k') | net/url_request/sdch_dictionary_fetcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698