on master help sign in
moving an error case to the bottom.
commit4415eb2a46e4fac45e5fdad437d1fc5ce34859ad authorKazu Yamamoto <kazu@iij.ad.jp> dateWed 29 Jul 2015, 16:07 (11 years ago) parent66d99c4
1 file changed+1−2
warp/Network/Wai/Handler/Warp/HTTP2/Receiver.hs+1−2
warp/Network/Wai/Handler/Warp/HTTP2/Receiver.hs+1−2
@@ -300,8 +300,6 @@ stream FrameContinuation FrameHeader{flags} frag ctx (Open (Continued rfrags siz
300300 else
301301 return $ Open $ Continued rfrags' siz' n' endOfStream pri
302302
303−stream FrameContinuation _ _ _ _ _ = E.throwIO $ ConnectionError ProtocolError "continue frame cannot come here"
304−
305303stream FrameWindowUpdate header@FrameHeader{streamId} bs _ s Stream{streamWindow} = do
306304 WindowUpdateFrame n <- guardIt $ decodeWindowUpdateFrame header bs
307305 w <- (n +) <$> atomically (readTVar streamWindow)
@@ -323,6 +321,7 @@ stream FramePriority header bs Context{outputQ} s Stream{streamNumber} = do
323321 return s
324322
325323-- this ordering is important
324+stream FrameContinuation _ _ _ _ _ = E.throwIO $ ConnectionError ProtocolError "continue frame cannot come here"
326325stream _ _ _ _ (Open Continued{}) _ = E.throwIO $ ConnectionError ProtocolError "an illegal frame follows header/continuation frames"
327326-- Ignore frames to streams we have just reset, per section 5.1.
328327stream _ _ _ _ st@(Closed (ResetByMe _)) _ = return st