| 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/quic/core/quic_session.h" | 5 #include "net/quic/core/quic_session.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| (...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 155 bool ShouldCreateOutgoingDynamicStream() override { return true; } | 155 bool ShouldCreateOutgoingDynamicStream() override { return true; } |
| 156 | 156 |
| 157 bool IsClosedStream(QuicStreamId id) { | 157 bool IsClosedStream(QuicStreamId id) { |
| 158 return QuicSession::IsClosedStream(id); | 158 return QuicSession::IsClosedStream(id); |
| 159 } | 159 } |
| 160 | 160 |
| 161 QuicStream* GetOrCreateDynamicStream(QuicStreamId stream_id) { | 161 QuicStream* GetOrCreateDynamicStream(QuicStreamId stream_id) { |
| 162 return QuicSpdySession::GetOrCreateDynamicStream(stream_id); | 162 return QuicSpdySession::GetOrCreateDynamicStream(stream_id); |
| 163 } | 163 } |
| 164 | 164 |
| 165 QuicConsumedData WritevData( | 165 QuicConsumedData WritevData(QuicStream* stream, |
| 166 QuicStream* stream, | 166 QuicStreamId id, |
| 167 QuicStreamId id, | 167 QuicIOVector data, |
| 168 QuicIOVector data, | 168 QuicStreamOffset offset, |
| 169 QuicStreamOffset offset, | 169 bool fin, |
| 170 bool fin, | 170 const scoped_refptr<QuicAckListenerInterface>& |
| 171 QuicAckListenerInterface* ack_notifier_delegate) override { | 171 ack_notifier_delegate) override { |
| 172 QuicConsumedData consumed(data.total_length, fin); | 172 QuicConsumedData consumed(data.total_length, fin); |
| 173 if (!writev_consumes_all_data_) { | 173 if (!writev_consumes_all_data_) { |
| 174 consumed = QuicSession::WritevData(stream, id, data, offset, fin, | 174 consumed = QuicSession::WritevData(stream, id, data, offset, fin, |
| 175 ack_notifier_delegate); | 175 ack_notifier_delegate); |
| 176 } | 176 } |
| 177 stream->set_stream_bytes_written(stream->stream_bytes_written() + | 177 stream->set_stream_bytes_written(stream->stream_bytes_written() + |
| 178 consumed.bytes_consumed); | 178 consumed.bytes_consumed); |
| 179 if (fin && consumed.fin_consumed) { | 179 if (fin && consumed.fin_consumed) { |
| 180 stream->set_fin_sent(true); | 180 stream->set_fin_sent(true); |
| 181 } | 181 } |
| (...skipping 1131 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1313 if (version() <= QUIC_VERSION_35) { | 1313 if (version() <= QUIC_VERSION_35) { |
| 1314 EXPECT_FALSE(session_.force_hol_blocking()); | 1314 EXPECT_FALSE(session_.force_hol_blocking()); |
| 1315 } else { | 1315 } else { |
| 1316 EXPECT_TRUE(session_.force_hol_blocking()); | 1316 EXPECT_TRUE(session_.force_hol_blocking()); |
| 1317 } | 1317 } |
| 1318 } | 1318 } |
| 1319 | 1319 |
| 1320 } // namespace | 1320 } // namespace |
| 1321 } // namespace test | 1321 } // namespace test |
| 1322 } // namespace net | 1322 } // namespace net |
| OLD | NEW |