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

Unified Diff: trunk/src/net/quic/quic_stream_factory.cc

Issue 227083002: Revert 261966 "make SetReceiveBufferSize and SetSendBufferSize r..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 6 years, 8 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 | « trunk/src/net/http/http_proxy_client_socket.cc ('k') | trunk/src/net/socket/buffered_write_stream_socket.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/net/quic/quic_stream_factory.cc
===================================================================
--- trunk/src/net/quic/quic_stream_factory.cc (revision 262001)
+++ trunk/src/net/quic/quic_stream_factory.cc (working copy)
@@ -722,18 +722,16 @@
// does not consume "too much" memory. If we see bursty packet loss, we may
// revisit this setting and test for its impact.
const int32 kSocketBufferSize(TcpReceiver::kReceiveWindowTCP);
- rv = socket->SetReceiveBufferSize(kSocketBufferSize);
- if (rv != OK) {
+ if (!socket->SetReceiveBufferSize(kSocketBufferSize)) {
HistogramCreateSessionFailure(CREATION_ERROR_SETTING_RECEIVE_BUFFER);
- return rv;
+ return ERR_SOCKET_SET_RECEIVE_BUFFER_SIZE_ERROR;
}
// Set a buffer large enough to contain the initial CWND's worth of packet
// to work around the problem with CHLO packets being sent out with the
// wrong encryption level, when the send buffer is full.
- rv = socket->SetSendBufferSize(kMaxPacketSize * 20);
- if (rv != OK) {
+ if (!socket->SetSendBufferSize(kMaxPacketSize * 20)) {
HistogramCreateSessionFailure(CREATION_ERROR_SETTING_SEND_BUFFER);
- return rv;
+ return ERR_SOCKET_SET_SEND_BUFFER_SIZE_ERROR;
}
scoped_ptr<QuicDefaultPacketWriter> writer(
« no previous file with comments | « trunk/src/net/http/http_proxy_client_socket.cc ('k') | trunk/src/net/socket/buffered_write_stream_socket.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698