summaryrefslogtreecommitdiff
path: root/plugin/protocol/http2/src/http2_stream.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'plugin/protocol/http2/src/http2_stream.cpp')
-rw-r--r--plugin/protocol/http2/src/http2_stream.cpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/plugin/protocol/http2/src/http2_stream.cpp b/plugin/protocol/http2/src/http2_stream.cpp
index 797f2f7..907a8e8 100644
--- a/plugin/protocol/http2/src/http2_stream.cpp
+++ b/plugin/protocol/http2/src/http2_stream.cpp
@@ -1261,8 +1261,9 @@ nghttp2_submit_frame_data(struct tfe_h2_stream *h2_stream_info,const nghttp2_fra
nghttp2_session *ngh2_session = tfe_h2_stream_get_nghttp2_peer_session(h2_stream_info, dir);
h2_session = (struct tfe_h2_session *)nghttp2_session_get_stream_user_data(ngh2_session, frame->hd.stream_id);
- if (!h2_session)
+ if (h2_session == NULL)
{
+ nghttp2_submit_end_data_by_h2_half(h2_stream_info, frame->hd.stream_id, dir);
h2_stream_info->stream_action = ACTION_DROP_DATA;
return 0;
}
@@ -1615,6 +1616,8 @@ nghttp2_server_submit_header(struct tfe_h2_stream *h2_stream_info, int32_t strea
stream_id, h2_stream_info);
goto finish;
}
+ assert(h2_session->ngh2_stream_id == stream_id);
+
resp = h2_session->resp;
fill_resp_spec_from_handle(h2_session->resp);
@@ -1799,6 +1802,8 @@ nghttp2_client_submit_header(struct tfe_h2_stream *h2_stream_info, int32_t strea
stream_action = ACTION_FORWARD_DATA;
goto finish;
}
+ assert(h2_session->ngh2_stream_id == stream_id);
+
req = h2_session->req;
fill_req_spec_from_handle(h2_session->req);