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

Unified Diff: net/socket/tcp_client_socket_libevent.cc

Issue 7084007: Adds URLRequestJob bytes read to NetLog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: sync Created 9 years, 7 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
Index: net/socket/tcp_client_socket_libevent.cc
===================================================================
--- net/socket/tcp_client_socket_libevent.cc (revision 87467)
+++ net/socket/tcp_client_socket_libevent.cc (working copy)
@@ -435,8 +435,8 @@
read_bytes.Add(nread);
if (nread > 0)
use_history_.set_was_used_to_convey_data();
- LogByteTransfer(
- net_log_, NetLog::TYPE_SOCKET_BYTES_RECEIVED, nread, buf->data());
+ net_log_.AddByteTransferEvent(NetLog::TYPE_SOCKET_BYTES_RECEIVED, nread,
+ buf->data());
return nread;
}
if (errno != EAGAIN && errno != EWOULDBLOCK) {
@@ -474,8 +474,8 @@
write_bytes.Add(nwrite);
if (nwrite > 0)
use_history_.set_was_used_to_convey_data();
- LogByteTransfer(
- net_log_, NetLog::TYPE_SOCKET_BYTES_SENT, nwrite, buf->data());
+ net_log_.AddByteTransferEvent(NetLog::TYPE_SOCKET_BYTES_SENT, nwrite,
+ buf->data());
return nwrite;
}
if (errno != EAGAIN && errno != EWOULDBLOCK)
@@ -629,8 +629,8 @@
read_bytes.Add(bytes_transferred);
if (bytes_transferred > 0)
use_history_.set_was_used_to_convey_data();
- LogByteTransfer(net_log_, NetLog::TYPE_SOCKET_BYTES_RECEIVED, result,
- read_buf_->data());
+ net_log_.AddByteTransferEvent(NetLog::TYPE_SOCKET_BYTES_RECEIVED, result,
+ read_buf_->data());
} else {
result = MapSystemError(errno);
}
@@ -656,8 +656,8 @@
write_bytes.Add(bytes_transferred);
if (bytes_transferred > 0)
use_history_.set_was_used_to_convey_data();
- LogByteTransfer(net_log_, NetLog::TYPE_SOCKET_BYTES_SENT, result,
- write_buf_->data());
+ net_log_.AddByteTransferEvent(NetLog::TYPE_SOCKET_BYTES_SENT, result,
+ write_buf_->data());
} else {
result = MapSystemError(errno);
}

Powered by Google App Engine
This is Rietveld 408576698