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

Unified Diff: net/spdy/spdy_framer.cc

Issue 2644683002: Add HpackDecoder3, an adapter using HpackDecoder (in net/http2/hpack/decoder). (Closed)
Patch Set: Nits. Created 3 years, 11 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/spdy_flags.cc ('k') | net/spdy/spdy_framer_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_framer.cc
diff --git a/net/spdy/spdy_framer.cc b/net/spdy/spdy_framer.cc
index 85e842680e74e1b9b26001383f27123ae0bb0c66..db0628098deaf0c45dee43ba715825e3d2ac1472 100644
--- a/net/spdy/spdy_framer.cc
+++ b/net/spdy/spdy_framer.cc
@@ -25,6 +25,7 @@
#include "net/spdy/hpack/hpack_constants.h"
#include "net/spdy/hpack/hpack_decoder.h"
#include "net/spdy/hpack/hpack_decoder2.h"
+#include "net/spdy/hpack/hpack_decoder3.h"
#include "net/spdy/http2_frame_decoder_adapter.h"
#include "net/spdy/spdy_bitmasks.h"
#include "net/spdy/spdy_bug_tracker.h"
@@ -2471,7 +2472,11 @@ HpackEncoder* SpdyFramer::GetHpackEncoder() {
HpackDecoderInterface* SpdyFramer::GetHpackDecoder() {
if (hpack_decoder_.get() == nullptr) {
- if (FLAGS_chromium_http2_flag_spdy_use_hpack_decoder2) {
+ if (FLAGS_chromium_http2_flag_spdy_use_hpack_decoder3) {
+ SPDY_BUG_IF(FLAGS_chromium_http2_flag_spdy_use_hpack_decoder2)
+ << "Both alternate decoders are enabled.";
+ hpack_decoder_.reset(new HpackDecoder3());
+ } else if (FLAGS_chromium_http2_flag_spdy_use_hpack_decoder2) {
hpack_decoder_.reset(new HpackDecoder2());
} else {
hpack_decoder_.reset(new HpackDecoder());
« no previous file with comments | « net/spdy/spdy_flags.cc ('k') | net/spdy/spdy_framer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698