Chromium Code Reviews| 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..ddd8623845f9b1abeaa03b6cd235fc100eadc4f3 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()->AddBytesRead(result); |
|
eroman
2014/11/13 22:18:39
Probably not worth micro-optimizing, but I wonder
Ryan Hamilton
2014/11/13 23:38:18
Heh, I thought about that too. I suspect that's *p
eroman
2014/11/14 00:06:15
Meh, i was mostly just bikeshedding. Probably bett
|
| } |
| 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()->AddBytesWritten(result); |
| } |
| int UDPSocketWin::InternalRecvFrom(IOBuffer* buf, int buf_len, |