Chromium Code Reviews| 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/spdy/spdy_test_util_spdy3.h" | 5 #include "net/spdy/spdy_test_util_spdy3.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 193 // Construct a SPDY PING frame. | 193 // Construct a SPDY PING frame. |
| 194 // Returns the constructed frame. The caller takes ownership of the frame. | 194 // Returns the constructed frame. The caller takes ownership of the frame. |
| 195 SpdyFrame* ConstructSpdyPing(uint32 ping_id) { | 195 SpdyFrame* ConstructSpdyPing(uint32 ping_id) { |
| 196 BufferedSpdyFramer framer(3, false); | 196 BufferedSpdyFramer framer(3, false); |
| 197 return framer.CreatePingFrame(ping_id); | 197 return framer.CreatePingFrame(ping_id); |
| 198 } | 198 } |
| 199 | 199 |
| 200 // Construct a SPDY GOAWAY frame. | 200 // Construct a SPDY GOAWAY frame. |
| 201 // Returns the constructed frame. The caller takes ownership of the frame. | 201 // Returns the constructed frame. The caller takes ownership of the frame. |
| 202 SpdyFrame* ConstructSpdyGoAway() { | 202 SpdyFrame* ConstructSpdyGoAway() { |
| 203 return ConstructSpdyGoAway(0); | |
| 204 } | |
| 205 | |
| 206 // Construct a SPDY GOAWAY frame. | |
|
akalin
2013/04/17 21:14:20
here too
Ryan Hamilton
2013/04/18 00:30:40
ditto :>
| |
| 207 // Returns the constructed frame. The caller takes ownership of the frame. | |
| 208 SpdyFrame* ConstructSpdyGoAway(SpdyStreamId last_good_stream_id) { | |
| 203 BufferedSpdyFramer framer(3, false); | 209 BufferedSpdyFramer framer(3, false); |
| 204 return framer.CreateGoAway(0, GOAWAY_OK); | 210 return framer.CreateGoAway(last_good_stream_id, GOAWAY_OK); |
| 205 } | 211 } |
| 206 | 212 |
| 207 // Construct a SPDY WINDOW_UPDATE frame. | 213 // Construct a SPDY WINDOW_UPDATE frame. |
| 208 // Returns the constructed frame. The caller takes ownership of the frame. | 214 // Returns the constructed frame. The caller takes ownership of the frame. |
| 209 SpdyFrame* ConstructSpdyWindowUpdate( | 215 SpdyFrame* ConstructSpdyWindowUpdate( |
| 210 const SpdyStreamId stream_id, uint32 delta_window_size) { | 216 const SpdyStreamId stream_id, uint32 delta_window_size) { |
| 211 BufferedSpdyFramer framer(3, false); | 217 BufferedSpdyFramer framer(3, false); |
| 212 return framer.CreateWindowUpdate(stream_id, delta_window_size); | 218 return framer.CreateWindowUpdate(stream_id, delta_window_size); |
| 213 } | 219 } |
| 214 | 220 |
| (...skipping 718 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 933 NULL, // Data | 939 NULL, // Data |
| 934 0, // Length | 940 0, // Length |
| 935 DATA_FLAG_NONE // Data Flags | 941 DATA_FLAG_NONE // Data Flags |
| 936 }; | 942 }; |
| 937 return kHeader; | 943 return kHeader; |
| 938 } | 944 } |
| 939 | 945 |
| 940 } // namespace test_spdy3 | 946 } // namespace test_spdy3 |
| 941 | 947 |
| 942 } // namespace net | 948 } // namespace net |
| OLD | NEW |