Index: net/spdy/spdy_headers_block_parser.h |
diff --git a/net/spdy/spdy_headers_block_parser.h b/net/spdy/spdy_headers_block_parser.h |
index b853b91047e6219ea5b4af57df65a6d79ceaef07..2c9207cc5bc1d0c1c54bdbe80e4e5c3d6d904b94 100644 |
--- a/net/spdy/spdy_headers_block_parser.h |
+++ b/net/spdy/spdy_headers_block_parser.h |
@@ -31,8 +31,9 @@ class SpdyHeadersHandlerInterface { |
base::StringPiece value) = 0; |
// A callback method which notifies when the parser finishes handling a SPDY |
- // headers block. |
- virtual void OnHeaderBlockEnd(SpdyStreamId stream_id) = 0; |
+ // headers block. Also notifies on the total number of bytes in this block. |
+ virtual void OnHeaderBlockEnd(SpdyStreamId stream_id, |
+ size_t header_bytes_parsed) = 0; |
}; |
namespace test { |
@@ -116,6 +117,9 @@ class NET_EXPORT_PRIVATE SpdyHeadersBlockParser { |
// The maximal number of headers in a SPDY headers block. |
const size_t max_headers_in_block_; |
+ // A running total of the bytes parsed since the last call to Reset(). |
+ size_t total_bytes_received_; |
+ |
// Number of key-value pairs until we complete handling the current |
// headers block. |
uint32_t remaining_key_value_pairs_for_frame_; |