| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_headers_stream.h" | 5 #include "net/quic/quic_headers_stream.h" |
| 6 | 6 |
| 7 #include "net/quic/quic_session.h" | 7 #include "net/quic/quic_session.h" |
| 8 | 8 |
| 9 using base::StringPiece; | 9 using base::StringPiece; |
| 10 | 10 |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 172 | 172 |
| 173 QuicHeadersStream::QuicHeadersStream(QuicSession* session) | 173 QuicHeadersStream::QuicHeadersStream(QuicSession* session) |
| 174 : ReliableQuicStream(kHeadersStreamId, session), | 174 : ReliableQuicStream(kHeadersStreamId, session), |
| 175 stream_id_(kInvalidStreamId), | 175 stream_id_(kInvalidStreamId), |
| 176 fin_(false), | 176 fin_(false), |
| 177 frame_len_(0), | 177 frame_len_(0), |
| 178 spdy_framer_(SPDY3), | 178 spdy_framer_(SPDY3), |
| 179 spdy_framer_visitor_(new SpdyFramerVisitor(this)) { | 179 spdy_framer_visitor_(new SpdyFramerVisitor(this)) { |
| 180 spdy_framer_.set_visitor(spdy_framer_visitor_.get()); | 180 spdy_framer_.set_visitor(spdy_framer_visitor_.get()); |
| 181 spdy_framer_.set_debug_visitor(spdy_framer_visitor_.get()); | 181 spdy_framer_.set_debug_visitor(spdy_framer_visitor_.get()); |
| 182 if (version() <= QUIC_VERSION_20) { | 182 if (version() < QUIC_VERSION_21) { |
| 183 // Prior to QUIC_VERSION_21 the headers stream is not subject to any flow | 183 // Prior to QUIC_VERSION_21 the headers stream is not subject to any flow |
| 184 // control. | 184 // control. |
| 185 DisableFlowControl(); | 185 DisableFlowControl(); |
| 186 } | 186 } |
| 187 // The headers stream is exempt from connection level flow control. | 187 // The headers stream is exempt from connection level flow control. |
| 188 DisableConnectionFlowControlForThisStream(); | 188 DisableConnectionFlowControlForThisStream(); |
| 189 } | 189 } |
| 190 | 190 |
| 191 QuicHeadersStream::~QuicHeadersStream() {} | 191 QuicHeadersStream::~QuicHeadersStream() {} |
| 192 | 192 |
| (...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 DCHECK_EQ(kInvalidStreamId, stream_id_); | 267 DCHECK_EQ(kInvalidStreamId, stream_id_); |
| 268 DCHECK_EQ(0u, frame_len_); | 268 DCHECK_EQ(0u, frame_len_); |
| 269 frame_len_ = frame_len; | 269 frame_len_ = frame_len; |
| 270 } | 270 } |
| 271 | 271 |
| 272 bool QuicHeadersStream::IsConnected() { | 272 bool QuicHeadersStream::IsConnected() { |
| 273 return session()->connection()->connected(); | 273 return session()->connection()->connected(); |
| 274 } | 274 } |
| 275 | 275 |
| 276 } // namespace net | 276 } // namespace net |
| OLD | NEW |