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

Side by Side Diff: net/quic/quic_reliable_client_stream.cc

Issue 306013009: Remove the TransmissionType argument from QuicConnection CanWrite and (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 6 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
« no previous file with comments | « net/quic/quic_connection.cc ('k') | net/quic/quic_sent_packet_manager.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "net/quic/quic_reliable_client_stream.h" 5 #include "net/quic/quic_reliable_client_stream.h"
6 6
7 #include "base/callback_helpers.h" 7 #include "base/callback_helpers.h"
8 #include "net/base/net_errors.h" 8 #include "net/base/net_errors.h"
9 #include "net/quic/quic_session.h" 9 #include "net/quic/quic_session.h"
10 #include "net/quic/quic_write_blocked_list.h" 10 #include "net/quic/quic_write_blocked_list.h"
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
86 86
87 void QuicReliableClientStream::OnError(int error) { 87 void QuicReliableClientStream::OnError(int error) {
88 if (delegate_) { 88 if (delegate_) {
89 QuicReliableClientStream::Delegate* delegate = delegate_; 89 QuicReliableClientStream::Delegate* delegate = delegate_;
90 delegate_ = NULL; 90 delegate_ = NULL;
91 delegate->OnError(error); 91 delegate->OnError(error);
92 } 92 }
93 } 93 }
94 94
95 bool QuicReliableClientStream::CanWrite(const CompletionCallback& callback) { 95 bool QuicReliableClientStream::CanWrite(const CompletionCallback& callback) {
96 bool can_write = session()->connection()->CanWrite( 96 bool can_write = session()->connection()->CanWrite(HAS_RETRANSMITTABLE_DATA);
97 NOT_RETRANSMISSION, HAS_RETRANSMITTABLE_DATA);
98 if (!can_write) { 97 if (!can_write) {
99 session()->MarkWriteBlocked(id(), EffectivePriority()); 98 session()->MarkWriteBlocked(id(), EffectivePriority());
100 DCHECK(callback_.is_null()); 99 DCHECK(callback_.is_null());
101 callback_ = callback; 100 callback_ = callback;
102 } 101 }
103 return can_write; 102 return can_write;
104 } 103 }
105 104
106 } // namespace net 105 } // namespace net
OLDNEW
« no previous file with comments | « net/quic/quic_connection.cc ('k') | net/quic/quic_sent_packet_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698