mirror of
https://github.com/curl/curl.git
synced 2025-03-19 15:40:42 +08:00
http2: Fix bug that associated stream canceled on PUSH_PROMISE
Previously we don't ignore PUSH_PROMISE header fields in on_header callback. It makes header values mixed with following HEADERS, resulting protocol error.
This commit is contained in:
parent
20c727ec4c
commit
7eebf9a3fb
@ -424,6 +424,11 @@ static int on_header(nghttp2_session *session, const nghttp2_frame *frame,
|
||||
(void)frame;
|
||||
(void)flags;
|
||||
|
||||
/* Ignore PUSH_PROMISE for now */
|
||||
if(frame->hd.type != NGHTTP2_HEADERS) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
if(frame->hd.stream_id != c->stream_id) {
|
||||
return 0;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user