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

Side by Side Diff: remoting/jingle_glue/ssl_socket_adapter.cc

Issue 7251004: Deciding best connection to schedule requests on based on cwnd and idle time (Reopened after revert) (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Syncing to head Created 9 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "remoting/jingle_glue/ssl_socket_adapter.h" 5 #include "remoting/jingle_glue/ssl_socket_adapter.h"
6 6
7 #include "base/base64.h" 7 #include "base/base64.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "jingle/glue/utils.h" 10 #include "jingle/glue/utils.h"
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after
263 bool TransportSocket::WasEverUsed() const { 263 bool TransportSocket::WasEverUsed() const {
264 // We don't use this in ClientSocketPools, so this should never be used. 264 // We don't use this in ClientSocketPools, so this should never be used.
265 NOTREACHED(); 265 NOTREACHED();
266 return was_used_to_convey_data_; 266 return was_used_to_convey_data_;
267 } 267 }
268 268
269 bool TransportSocket::UsingTCPFastOpen() const { 269 bool TransportSocket::UsingTCPFastOpen() const {
270 return false; 270 return false;
271 } 271 }
272 272
273 int64 TransportSocket::NumBytesRead() const {
274 NOTREACHED();
275 return -1;
276 }
277
278 base::TimeDelta TransportSocket::GetConnectTimeMicros() const {
279 NOTREACHED();
280 return base::TimeDelta::FromMicroseconds(-1);
281 }
282
273 int TransportSocket::Read(net::IOBuffer* buf, int buf_len, 283 int TransportSocket::Read(net::IOBuffer* buf, int buf_len,
274 net::CompletionCallback* callback) { 284 net::CompletionCallback* callback) {
275 DCHECK(buf); 285 DCHECK(buf);
276 DCHECK(!read_callback_); 286 DCHECK(!read_callback_);
277 DCHECK(!read_buffer_.get()); 287 DCHECK(!read_buffer_.get());
278 int result = socket_->Recv(buf->data(), buf_len); 288 int result = socket_->Recv(buf->data(), buf_len);
279 if (result < 0) { 289 if (result < 0) {
280 result = net::MapSystemError(socket_->GetError()); 290 result = net::MapSystemError(socket_->GetError());
281 if (result == net::ERR_IO_PENDING) { 291 if (result == net::ERR_IO_PENDING) {
282 read_callback_ = callback; 292 read_callback_ = callback;
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
364 write_buffer_len_ = buffer_len; 374 write_buffer_len_ = buffer_len;
365 return; 375 return;
366 } 376 }
367 } 377 }
368 was_used_to_convey_data_ = true; 378 was_used_to_convey_data_ = true;
369 callback->RunWithParams(Tuple1<int>(result)); 379 callback->RunWithParams(Tuple1<int>(result));
370 } 380 }
371 } 381 }
372 382
373 } // namespace remoting 383 } // namespace remoting
OLDNEW
« net/socket/stream_socket.h ('K') | « remoting/jingle_glue/ssl_socket_adapter.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698