diff options
author | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-09 04:34:47 +0000 |
---|---|---|
committer | eroman@chromium.org <eroman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-04-09 04:34:47 +0000 |
commit | 1f0e32b947057d19c6772587e72799f2644119f1 (patch) | |
tree | 57fcee3c417e40c87cb81bf316ccef45a1878e0f /net/socket_stream/socket_stream.cc | |
parent | 3ef4bc6355b48c74928feefd8bbaff501bb8d59f (diff) | |
download | chromium_src-1f0e32b947057d19c6772587e72799f2644119f1.zip chromium_src-1f0e32b947057d19c6772587e72799f2644119f1.tar.gz chromium_src-1f0e32b947057d19c6772587e72799f2644119f1.tar.bz2 |
Add support for attaching custom parameters to NetLog events.
BUG=37421
Review URL: http://codereview.chromium.org/1556018
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@44057 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'net/socket_stream/socket_stream.cc')
-rw-r--r-- | net/socket_stream/socket_stream.cc | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/socket_stream/socket_stream.cc b/net/socket_stream/socket_stream.cc index bdd2894..8a78659 100644 --- a/net/socket_stream/socket_stream.cc +++ b/net/socket_stream/socket_stream.cc @@ -97,8 +97,7 @@ void SocketStream::set_context(URLRequestContext* context) { context->net_log(), NetLog::SOURCE_SOCKET_STREAM); - net_log_.BeginEventWithString(NetLog::TYPE_REQUEST_ALIVE, - url_.possibly_invalid_spec()); + net_log_.BeginEvent(NetLog::TYPE_REQUEST_ALIVE); } } @@ -121,7 +120,8 @@ void SocketStream::Connect() { // Open a connection asynchronously, so that delegate won't be called // back before returning Connect(). next_state_ = STATE_RESOLVE_PROXY; - net_log_.BeginEvent(NetLog::TYPE_SOCKET_STREAM_CONNECT); + net_log_.BeginEventWithString(NetLog::TYPE_SOCKET_STREAM_CONNECT, + url_.possibly_invalid_spec()); MessageLoop::current()->PostTask( FROM_HERE, NewRunnableMethod(this, &SocketStream::DoLoop, OK)); @@ -406,7 +406,7 @@ void SocketStream::DoLoop(int result) { // close the connection. if (state != STATE_READ_WRITE && result < ERR_IO_PENDING) { DCHECK_EQ(next_state_, STATE_CLOSE); - net_log_.EndEvent(NetLog::TYPE_SOCKET_STREAM_CONNECT); + net_log_.EndEventWithInteger(NetLog::TYPE_SOCKET_STREAM_CONNECT, result); } } while (result != ERR_IO_PENDING); } |