From 2c463b64a5444e284458115afe12853cbda70b05 Mon Sep 17 00:00:00 2001 From: Nicholas Hurley Date: Wed, 28 Jun 2017 10:28:54 -0700 Subject: [PATCH] Bug 1368080 - Use REFUSED_STREAM instead of INTERNAL_ERROR on duplicate push key. r=mcmanus MozReview-Commit-ID: BEUo6YpcyZj --HG-- extra : rebase_source : 7733620d2149bac35201c74ab451ebb292268442 --- netwerk/protocol/http/Http2Session.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/netwerk/protocol/http/Http2Session.cpp b/netwerk/protocol/http/Http2Session.cpp index 2ee3a577a27b..a3d33dac5eb6 100644 --- a/netwerk/protocol/http/Http2Session.cpp +++ b/netwerk/protocol/http/Http2Session.cpp @@ -1832,8 +1832,9 @@ Http2Session::RecvPushPromise(Http2Session *self) } else { LOG3(("Http2Session::RecvPushPromise %p place stream into session cache\n", self)); if (!cache->RegisterPushedStreamHttp2(key, pushedStream)) { + // This only happens if they've already pushed us this item. LOG3(("Http2Session::RecvPushPromise registerPushedStream Failed\n")); - self->CleanupStream(pushedStream, NS_ERROR_FAILURE, INTERNAL_ERROR); + self->CleanupStream(pushedStream, NS_ERROR_FAILURE, REFUSED_STREAM_ERROR); self->ResetDownstreamState(); return NS_OK; }