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

Unified Diff: net/socket/ssl_client_socket_openssl.cc

Issue 869393005: Perform ClientHello padding if the field trial is enabled (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@net_connection_error_uma
Patch Set: CR comment updates Created 5 years, 10 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/ssl_client_socket_openssl.cc
diff --git a/net/socket/ssl_client_socket_openssl.cc b/net/socket/ssl_client_socket_openssl.cc
index c4af9575f1e447939f3e76fbce7f43fd4896cf92..93f7b85dc76e353a8f5b55666caad3e659cbf7e6 100644
--- a/net/socket/ssl_client_socket_openssl.cc
+++ b/net/socket/ssl_client_socket_openssl.cc
@@ -18,7 +18,6 @@
#include "base/environment.h"
#include "base/memory/singleton.h"
#include "base/metrics/histogram.h"
-#include "base/metrics/sparse_histogram.h"
#include "base/profiler/scoped_tracker.h"
#include "base/strings/string_piece.h"
#include "base/synchronization/lock.h"
@@ -473,20 +472,21 @@ int SSLClientSocketOpenSSL::Connect(const CompletionCallback& callback) {
int rv = Init();
if (rv != OK) {
net_log_.EndEventWithNetErrorCode(NetLog::TYPE_SSL_CONNECT, rv);
- UMA_HISTOGRAM_SPARSE_SLOWLY("Net.SSL_Connection_Error", std::abs(rv));
return rv;
}
// Set SSL to client mode. Handshake happens in the loop below.
SSL_set_connect_state(ssl_);
+ // Enable fastradio padding.
+ SSL_enable_fastradio_padding(ssl_, ssl_config_.enable_fastradio_padding);
+
GotoState(STATE_HANDSHAKE);
rv = DoHandshakeLoop(OK);
if (rv == ERR_IO_PENDING) {
user_connect_callback_ = callback;
} else {
net_log_.EndEventWithNetErrorCode(NetLog::TYPE_SSL_CONNECT, rv);
- UMA_HISTOGRAM_SPARSE_SLOWLY("Net.SSL_Connection_Error", std::abs(rv));
if (rv < OK)
OnHandshakeCompletion();
}
@@ -1366,7 +1366,6 @@ void SSLClientSocketOpenSSL::OnHandshakeIOComplete(int result) {
int rv = DoHandshakeLoop(result);
if (rv != ERR_IO_PENDING) {
net_log_.EndEventWithNetErrorCode(NetLog::TYPE_SSL_CONNECT, rv);
- UMA_HISTOGRAM_SPARSE_SLOWLY("Net.SSL_Connection_Error", std::abs(rv));
DoConnectCallback(rv);
}
}

Powered by Google App Engine
This is Rietveld 408576698