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

Unified Diff: net/socket/socket_test_util.cc

Issue 8892026: SPDY - add support for spdy/2.1 to support flow control. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years 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/socket/socket_test_util.h ('k') | net/socket/ssl_client_socket.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/socket/socket_test_util.cc
===================================================================
--- net/socket/socket_test_util.cc (revision 113884)
+++ net/socket/socket_test_util.cc (working copy)
@@ -1063,7 +1063,9 @@
transport_(transport_socket),
data_(data),
is_npn_state_set_(false),
- new_npn_value_(false) {
+ new_npn_value_(false),
+ is_next_protocol_set_(false),
+ next_protocol_(kProtoHTTP11) {
DCHECK(data_);
delete ssl_host_info; // we take ownership but don't use it.
}
@@ -1159,6 +1161,19 @@
return new_npn_value_ = negotiated;
}
+SSLClientSocket::NextProto MockSSLClientSocket::next_protocol_negotiated()
+ const {
+ if (is_next_protocol_set_)
+ return next_protocol_;
+ return SSLClientSocket::NextProtoFromString(data_->next_proto);
+}
+
+void MockSSLClientSocket::set_next_protocol_negotiated(
+ SSLClientSocket::NextProto next_protocol) {
+ is_next_protocol_set_ = true;
+ next_protocol_ = next_protocol;
+}
+
void MockSSLClientSocket::OnReadComplete(const MockRead& data) {
NOTIMPLEMENTED();
}
« no previous file with comments | « net/socket/socket_test_util.h ('k') | net/socket/ssl_client_socket.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698