Skip to content

Commit 0d59371

Browse files
authored
Merge pull request #343 from ngtcp2/fix-fuzz
Fix fuzzer failure
2 parents 4fffb2f + 98f8121 commit 0d59371

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/nghttp3_stream.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1097,7 +1097,7 @@ int nghttp3_stream_transit_rx_http_state(nghttp3_stream *stream,
10971097
stream->rx.hstate = NGHTTP3_HTTP_STATE_REQ_END;
10981098
return 0;
10991099
case NGHTTP3_HTTP_STATE_REQ_END:
1100-
nghttp3_unreachable();
1100+
return NGHTTP3_ERR_H3_FRAME_UNEXPECTED;
11011101
case NGHTTP3_HTTP_STATE_RESP_INITIAL:
11021102
if (event != NGHTTP3_HTTP_EVENT_HEADERS_BEGIN) {
11031103
return NGHTTP3_ERR_H3_FRAME_UNEXPECTED;
@@ -1178,7 +1178,7 @@ int nghttp3_stream_transit_rx_http_state(nghttp3_stream *stream,
11781178
stream->rx.hstate = NGHTTP3_HTTP_STATE_RESP_END;
11791179
return 0;
11801180
case NGHTTP3_HTTP_STATE_RESP_END:
1181-
nghttp3_unreachable();
1181+
return NGHTTP3_ERR_H3_FRAME_UNEXPECTED;
11821182
default:
11831183
nghttp3_unreachable();
11841184
}

0 commit comments

Comments
 (0)