修复HTTP2流close删除应答信息,导致同一流id情况下无妨访问

This commit is contained in:
fengweihao
2019-09-20 19:32:04 +08:00
parent da8784bf5b
commit aa89caa453

View File

@@ -760,6 +760,7 @@ nghttp2_frame_submit_built_resp(struct tfe_h2_stream *h2_stream_info,
if (rv != 0){
return ACTION_FORWARD_DATA;
}
delete_nv_packet_data(h2_header);
return ACTION_DROP_DATA;
}
@@ -804,6 +805,7 @@ nghttp2_frame_submit_built_req(struct tfe_h2_stream *h2_stream_info,
nghttp2_strerror(stream_id));
return ACTION_FORWARD_DATA;
}
delete_nv_packet_data(h2_header);
return ACTION_DROP_DATA;
}
@@ -1193,6 +1195,7 @@ nghttp2_submit_header_by_not_modify(struct tfe_h2_stream *h2_stream_info,
printf("Fatal headers error: %s\n", nghttp2_strerror(stream_id));
stream_action = ACTION_FORWARD_DATA;
}
delete_nv_packet_data(&headers);
if (stream_action == ACTION_DROP_DATA){
xret = nghttp2_session_send(h2_stream_info->as_server);
@@ -1382,6 +1385,7 @@ nghttp2_server_frame_submit_push_promise(struct tfe_h2_stream *h2_stream_info,
}
upstream_create_req(h2_stream_info, h2_stream_info->as_server, peer_h2_stream, stream_id);
/*clean header message **/
delete_nv_packet_data(headers);
stream_action = ACTION_DROP_DATA;
finish:
return stream_action;
@@ -1590,6 +1594,7 @@ nghttp2_server_frame_submit_header(struct tfe_h2_stream *h2_stream_info,
if (xret < 0){
printf("Fatal headers error: %s\n", nghttp2_strerror(xret));
}
delete_nv_packet_data(headers);
return stream_action;
}
@@ -1773,6 +1778,7 @@ nghttp2_client_frame_submit_header(struct tfe_h2_stream *h2_stream_info,
}
stream_action = ACTION_DROP_DATA;
finish:
delete_nv_packet_data(headers);
return stream_action;
}