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_connection.h" | 5 #include "net/quic/quic_connection.h" |
6 | 6 |
7 #include <string.h> | 7 #include <string.h> |
8 #include <sys/types.h> | 8 #include <sys/types.h> |
9 #include <algorithm> | 9 #include <algorithm> |
10 #include <iterator> | 10 #include <iterator> |
(...skipping 824 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
835 | 835 |
836 QuicStopWaitingFrame* QuicConnection::CreateStopWaitingFrame() { | 836 QuicStopWaitingFrame* QuicConnection::CreateStopWaitingFrame() { |
837 QuicStopWaitingFrame stop_waiting; | 837 QuicStopWaitingFrame stop_waiting; |
838 UpdateStopWaiting(&stop_waiting); | 838 UpdateStopWaiting(&stop_waiting); |
839 return new QuicStopWaitingFrame(stop_waiting); | 839 return new QuicStopWaitingFrame(stop_waiting); |
840 } | 840 } |
841 | 841 |
842 bool QuicConnection::ShouldLastPacketInstigateAck() const { | 842 bool QuicConnection::ShouldLastPacketInstigateAck() const { |
843 if (!last_stream_frames_.empty() || | 843 if (!last_stream_frames_.empty() || |
844 !last_goaway_frames_.empty() || | 844 !last_goaway_frames_.empty() || |
845 !last_rst_frames_.empty()) { | 845 !last_rst_frames_.empty() || |
| 846 !last_window_update_frames_.empty() || |
| 847 !last_blocked_frames_.empty()) { |
846 return true; | 848 return true; |
847 } | 849 } |
848 | 850 |
849 if (!last_ack_frames_.empty() && | 851 if (!last_ack_frames_.empty() && |
850 last_ack_frames_.back().received_info.is_truncated) { | 852 last_ack_frames_.back().received_info.is_truncated) { |
851 return true; | 853 return true; |
852 } | 854 } |
853 return false; | 855 return false; |
854 } | 856 } |
855 | 857 |
(...skipping 924 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1780 // If we changed the generator's batch state, restore original batch state. | 1782 // If we changed the generator's batch state, restore original batch state. |
1781 if (!already_in_batch_mode_) { | 1783 if (!already_in_batch_mode_) { |
1782 DVLOG(1) << "Leaving Batch Mode."; | 1784 DVLOG(1) << "Leaving Batch Mode."; |
1783 connection_->packet_generator_.FinishBatchOperations(); | 1785 connection_->packet_generator_.FinishBatchOperations(); |
1784 } | 1786 } |
1785 DCHECK_EQ(already_in_batch_mode_, | 1787 DCHECK_EQ(already_in_batch_mode_, |
1786 connection_->packet_generator_.InBatchMode()); | 1788 connection_->packet_generator_.InBatchMode()); |
1787 } | 1789 } |
1788 | 1790 |
1789 } // namespace net | 1791 } // namespace net |
OLD | NEW |