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/quic_http_stream.h" | 5 #include "net/quic/quic_http_stream.h" |
6 | 6 |
7 #include "base/callback_helpers.h" | 7 #include "base/callback_helpers.h" |
8 #include "base/metrics/histogram_macros.h" | 8 #include "base/metrics/histogram_macros.h" |
9 #include "base/strings/stringprintf.h" | 9 #include "base/strings/stringprintf.h" |
10 #include "net/base/io_buffer.h" | 10 #include "net/base/io_buffer.h" |
(...skipping 504 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
515 response_info_->request_time = request_time_; | 515 response_info_->request_time = request_time_; |
516 response_headers_received_ = true; | 516 response_headers_received_ = true; |
517 | 517 |
518 return OK; | 518 return OK; |
519 } | 519 } |
520 | 520 |
521 int QuicHttpStream::ReadAvailableData(IOBuffer* buf, int buf_len) { | 521 int QuicHttpStream::ReadAvailableData(IOBuffer* buf, int buf_len) { |
522 int rv = stream_->Read(buf, buf_len); | 522 int rv = stream_->Read(buf, buf_len); |
523 if (stream_->IsDoneReading()) { | 523 if (stream_->IsDoneReading()) { |
524 stream_->SetDelegate(nullptr); | 524 stream_->SetDelegate(nullptr); |
525 stream_->DoneReading(); | 525 stream_->OnFinRead(); |
526 stream_ = nullptr; | 526 stream_ = nullptr; |
527 } | 527 } |
528 return rv; | 528 return rv; |
529 } | 529 } |
530 | 530 |
531 SpdyMajorVersion QuicHttpStream::GetSpdyVersion() { | 531 SpdyMajorVersion QuicHttpStream::GetSpdyVersion() { |
532 return SpdyUtils::GetSpdyVersionForQuicVersion(stream_->version()); | 532 return SpdyUtils::GetSpdyVersionForQuicVersion(stream_->version()); |
533 } | 533 } |
534 | 534 |
535 } // namespace net | 535 } // namespace net |
OLD | NEW |