OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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_per_connection_packet_writer.h" | 5 #include "net/quic/quic_per_connection_packet_writer.h" |
6 | 6 |
7 #include "net/quic/quic_server_packet_writer.h" | 7 #include "net/quic/quic_server_packet_writer.h" |
8 #include "net/quic/quic_types.h" | 8 #include "net/quic/quic_types.h" |
9 | 9 |
10 namespace net { | 10 namespace net { |
(...skipping 26 matching lines...) Expand all Loading... |
37 | 37 |
38 bool QuicPerConnectionPacketWriter::IsWriteBlocked() const { | 38 bool QuicPerConnectionPacketWriter::IsWriteBlocked() const { |
39 return writer_->IsWriteBlocked(); | 39 return writer_->IsWriteBlocked(); |
40 } | 40 } |
41 | 41 |
42 void QuicPerConnectionPacketWriter::SetWritable() { | 42 void QuicPerConnectionPacketWriter::SetWritable() { |
43 writer_->SetWritable(); | 43 writer_->SetWritable(); |
44 } | 44 } |
45 | 45 |
46 void QuicPerConnectionPacketWriter::OnWriteComplete(WriteResult result) { | 46 void QuicPerConnectionPacketWriter::OnWriteComplete(WriteResult result) { |
47 connection_->OnPacketSent(result); | 47 if (result.status == WRITE_STATUS_ERROR) { |
| 48 connection_->OnWriteError(result.error_code); |
| 49 } |
48 } | 50 } |
49 | 51 |
50 } // namespace net | 52 } // namespace net |
OLD | NEW |