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

Unified Diff: net/http/http_proxy_client_socket.cc

Issue 2315613002: Extracted NetLog class's inner enum types into their own enum classes and (Closed)
Patch Set: Ran "git cl format" on code. Much formatting ensued. Created 4 years, 3 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
« no previous file with comments | « net/http/http_network_transaction_unittest.cc ('k') | net/http/http_proxy_client_socket_pool.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/http/http_proxy_client_socket.cc
diff --git a/net/http/http_proxy_client_socket.cc b/net/http/http_proxy_client_socket.cc
index b84eeaad27bb7e3f33970500f50e7ba1900c6ac1..1d920ee9892d0a89498769f05ccde11c04fdcf5e 100644
--- a/net/http/http_proxy_client_socket.cc
+++ b/net/http/http_proxy_client_socket.cc
@@ -21,6 +21,7 @@
#include "net/http/http_stream_parser.h"
#include "net/http/proxy_connect_redirect_http_stream.h"
#include "net/log/net_log.h"
+#include "net/log/net_log_event_type.h"
#include "net/socket/client_socket_handle.h"
#include "url/gurl.h"
@@ -335,24 +336,24 @@ int HttpProxyClientSocket::DoLoop(int last_io_result) {
case STATE_SEND_REQUEST:
DCHECK_EQ(OK, rv);
net_log_.BeginEvent(
- NetLog::TYPE_HTTP_TRANSACTION_TUNNEL_SEND_REQUEST);
+ NetLogEventType::HTTP_TRANSACTION_TUNNEL_SEND_REQUEST);
rv = DoSendRequest();
break;
case STATE_SEND_REQUEST_COMPLETE:
rv = DoSendRequestComplete(rv);
net_log_.EndEventWithNetErrorCode(
- NetLog::TYPE_HTTP_TRANSACTION_TUNNEL_SEND_REQUEST, rv);
+ NetLogEventType::HTTP_TRANSACTION_TUNNEL_SEND_REQUEST, rv);
break;
case STATE_READ_HEADERS:
DCHECK_EQ(OK, rv);
net_log_.BeginEvent(
- NetLog::TYPE_HTTP_TRANSACTION_TUNNEL_READ_HEADERS);
+ NetLogEventType::HTTP_TRANSACTION_TUNNEL_READ_HEADERS);
rv = DoReadHeaders();
break;
case STATE_READ_HEADERS_COMPLETE:
rv = DoReadHeadersComplete(rv);
net_log_.EndEventWithNetErrorCode(
- NetLog::TYPE_HTTP_TRANSACTION_TUNNEL_READ_HEADERS, rv);
+ NetLogEventType::HTTP_TRANSACTION_TUNNEL_READ_HEADERS, rv);
break;
case STATE_DRAIN_BODY:
DCHECK_EQ(OK, rv);
@@ -408,10 +409,9 @@ int HttpProxyClientSocket::DoSendRequest() {
&request_line_, &request_headers_);
net_log_.AddEvent(
- NetLog::TYPE_HTTP_TRANSACTION_SEND_TUNNEL_HEADERS,
+ NetLogEventType::HTTP_TRANSACTION_SEND_TUNNEL_HEADERS,
base::Bind(&HttpRequestHeaders::NetLogCallback,
- base::Unretained(&request_headers_),
- &request_line_));
+ base::Unretained(&request_headers_), &request_line_));
}
parser_buf_ = new GrowableIOBuffer();
@@ -443,7 +443,7 @@ int HttpProxyClientSocket::DoReadHeadersComplete(int result) {
return ERR_TUNNEL_CONNECTION_FAILED;
net_log_.AddEvent(
- NetLog::TYPE_HTTP_TRANSACTION_READ_TUNNEL_RESPONSE_HEADERS,
+ NetLogEventType::HTTP_TRANSACTION_READ_TUNNEL_RESPONSE_HEADERS,
base::Bind(&HttpResponseHeaders::NetLogCallback, response_.headers));
if (proxy_delegate_) {
« no previous file with comments | « net/http/http_network_transaction_unittest.cc ('k') | net/http/http_proxy_client_socket_pool.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698