Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Unified Diff: net/spdy/chromium/header_coalescer.h

Issue 2847133003: Add NetLog event for invalid Http/2 response header (Closed)
Patch Set: address comments Created 3 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/spdy/chromium/buffered_spdy_framer_unittest.cc ('k') | net/spdy/chromium/header_coalescer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/chromium/header_coalescer.h
diff --git a/net/spdy/chromium/header_coalescer.h b/net/spdy/chromium/header_coalescer.h
index 31228adae3468177280b584fb7a14f7fa7d74839..9ba7652acc5b4bf75db1082d680662cd893148c6 100644
--- a/net/spdy/chromium/header_coalescer.h
+++ b/net/spdy/chromium/header_coalescer.h
@@ -6,6 +6,7 @@
#define NET_SPDY_HEADER_COALESCER_H_
#include "net/base/net_export.h"
+#include "net/log/net_log_with_source.h"
#include "net/spdy/core/spdy_header_block.h"
#include "net/spdy/core/spdy_headers_handler_interface.h"
#include "net/spdy/platform/api/spdy_string_piece.h"
@@ -14,7 +15,7 @@ namespace net {
class NET_EXPORT_PRIVATE HeaderCoalescer : public SpdyHeadersHandlerInterface {
public:
- HeaderCoalescer() {}
+ explicit HeaderCoalescer(const NetLogWithSource& net_log);
void OnHeaderBlockStart() override {}
@@ -31,11 +32,15 @@ class NET_EXPORT_PRIVATE HeaderCoalescer : public SpdyHeadersHandlerInterface {
size_t EstimateMemoryUsage() const;
private:
+ // Helper to add a header. Return true on success.
+ bool AddHeader(SpdyStringPiece key, SpdyStringPiece value);
+
SpdyHeaderBlock headers_;
bool headers_valid_ = true;
size_t header_list_size_ = 0;
bool error_seen_ = false;
bool regular_header_seen_ = false;
+ NetLogWithSource net_log_;
};
} // namespace net
« no previous file with comments | « net/spdy/chromium/buffered_spdy_framer_unittest.cc ('k') | net/spdy/chromium/header_coalescer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698