diff options
-rw-r--r-- | chrome/browser/resources/net_internals/source_entry.js | 8 | ||||
-rw-r--r-- | net/base/net_log_event_type_list.h | 6 | ||||
-rw-r--r-- | net/socket/client_socket_pool_base.cc | 6 |
3 files changed, 12 insertions, 8 deletions
diff --git a/chrome/browser/resources/net_internals/source_entry.js b/chrome/browser/resources/net_internals/source_entry.js index cc3b429..b223466 100644 --- a/chrome/browser/resources/net_internals/source_entry.js +++ b/chrome/browser/resources/net_internals/source_entry.js @@ -202,10 +202,14 @@ var SourceEntry = (function() { return e; } if (this.entries_.length >= 2) { - if (this.entries_[0].type == EventType.SOCKET_POOL_CONNECT_JOB || - this.entries_[1].type == EventType.UDP_CONNECT) { + // Needed for compatability with log dumps prior to M26. + // TODO(mmenke): Remove this. + if (this.entries_[0].type == EventType.SOCKET_POOL_CONNECT_JOB && + this.entries_[0].params == undefined) { return this.entries_[1]; } + if (this.entries_[1].type == EventType.UDP_CONNECT) + return this.entries_[1]; if (this.entries_[0].type == EventType.REQUEST_ALIVE && this.entries_[0].params == undefined) { var start_index = 1; diff --git a/net/base/net_log_event_type_list.h b/net/base/net_log_event_type_list.h index 54697a2..bbaeacc 100644 --- a/net/base/net_log_event_type_list.h +++ b/net/base/net_log_event_type_list.h @@ -600,15 +600,15 @@ EVENT_TYPE(UDP_SEND_ERROR) // ------------------------------------------------------------------------ // The start/end of a ConnectJob. -EVENT_TYPE(SOCKET_POOL_CONNECT_JOB) - -// The start/end of the ConnectJob::Connect(). // // The BEGIN phase has these parameters: // // { // "group_name": <The group name for the socket request.>, // } +EVENT_TYPE(SOCKET_POOL_CONNECT_JOB) + +// The start/end of the ConnectJob::Connect(). EVENT_TYPE(SOCKET_POOL_CONNECT_JOB_CONNECT) // This event is logged whenever the ConnectJob gets a new socket diff --git a/net/socket/client_socket_pool_base.cc b/net/socket/client_socket_pool_base.cc index 3e9cd82..1c12412 100644 --- a/net/socket/client_socket_pool_base.cc +++ b/net/socket/client_socket_pool_base.cc @@ -77,7 +77,8 @@ ConnectJob::ConnectJob(const std::string& group_name, idle_(true) { DCHECK(!group_name.empty()); DCHECK(delegate); - net_log.BeginEvent(NetLog::TYPE_SOCKET_POOL_CONNECT_JOB); + net_log.BeginEvent(NetLog::TYPE_SOCKET_POOL_CONNECT_JOB, + NetLog::StringCallback("group_name", &group_name_)); } ConnectJob::~ConnectJob() { @@ -125,8 +126,7 @@ void ConnectJob::ResetTimer(base::TimeDelta remaining_time) { } void ConnectJob::LogConnectStart() { - net_log().BeginEvent(NetLog::TYPE_SOCKET_POOL_CONNECT_JOB_CONNECT, - NetLog::StringCallback("group_name", &group_name_)); + net_log().BeginEvent(NetLog::TYPE_SOCKET_POOL_CONNECT_JOB_CONNECT); } void ConnectJob::LogConnectCompletion(int net_error) { |