| OLD | NEW |
| 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/tools/quic/quic_simple_server_session.h" | 5 #include "net/tools/quic/quic_simple_server_session.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/stl_util.h" | 8 #include "base/stl_util.h" |
| 9 #include "net/quic/proto/cached_network_parameters.pb.h" | 9 #include "net/quic/proto/cached_network_parameters.pb.h" |
| 10 #include "net/quic/quic_connection.h" | 10 #include "net/quic/quic_connection.h" |
| (...skipping 11 matching lines...) Expand all Loading... |
| 22 QuicServerSessionVisitor* visitor, | 22 QuicServerSessionVisitor* visitor, |
| 23 const QuicCryptoServerConfig* crypto_config) | 23 const QuicCryptoServerConfig* crypto_config) |
| 24 : QuicServerSessionBase(config, connection, visitor, crypto_config), | 24 : QuicServerSessionBase(config, connection, visitor, crypto_config), |
| 25 highest_promised_stream_id_(0) {} | 25 highest_promised_stream_id_(0) {} |
| 26 | 26 |
| 27 QuicSimpleServerSession::~QuicSimpleServerSession() {} | 27 QuicSimpleServerSession::~QuicSimpleServerSession() {} |
| 28 | 28 |
| 29 QuicCryptoServerStreamBase* | 29 QuicCryptoServerStreamBase* |
| 30 QuicSimpleServerSession::CreateQuicCryptoServerStream( | 30 QuicSimpleServerSession::CreateQuicCryptoServerStream( |
| 31 const QuicCryptoServerConfig* crypto_config) { | 31 const QuicCryptoServerConfig* crypto_config) { |
| 32 return new QuicCryptoServerStream(crypto_config, this); | 32 return new QuicCryptoServerStream( |
| 33 crypto_config, FLAGS_enable_quic_stateless_reject_support, this); |
| 33 } | 34 } |
| 34 | 35 |
| 35 void QuicSimpleServerSession::StreamDraining(QuicStreamId id) { | 36 void QuicSimpleServerSession::StreamDraining(QuicStreamId id) { |
| 36 QuicSpdySession::StreamDraining(id); | 37 QuicSpdySession::StreamDraining(id); |
| 37 if (!IsIncomingStream(id)) { | 38 if (!IsIncomingStream(id)) { |
| 38 HandlePromisedPushRequests(); | 39 HandlePromisedPushRequests(); |
| 39 } | 40 } |
| 40 } | 41 } |
| 41 | 42 |
| 42 void QuicSimpleServerSession::OnStreamFrame(const QuicStreamFrame& frame) { | 43 void QuicSimpleServerSession::OnStreamFrame(const QuicStreamFrame& frame) { |
| (...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 DVLOG(1) << "created server push stream " << promised_stream->id(); | 179 DVLOG(1) << "created server push stream " << promised_stream->id(); |
| 179 | 180 |
| 180 const SpdyHeaderBlock request_headers(promised_info.request_headers); | 181 const SpdyHeaderBlock request_headers(promised_info.request_headers); |
| 181 | 182 |
| 182 promised_streams_.pop_front(); | 183 promised_streams_.pop_front(); |
| 183 promised_stream->PushResponse(request_headers); | 184 promised_stream->PushResponse(request_headers); |
| 184 } | 185 } |
| 185 } | 186 } |
| 186 | 187 |
| 187 } // namespace net | 188 } // namespace net |
| OLD | NEW |