Don't send ALTSVC if stream is closing

This commit is contained in:
Tatsuhiro Tsujikawa 2016-04-15 00:59:05 +09:00
parent 81f81e6b70
commit 4041d1eb26
1 changed files with 3 additions and 0 deletions

View File

@ -1706,6 +1706,9 @@ static int session_predicate_altsvc_send(nghttp2_session *session,
if (stream == NULL) {
return NGHTTP2_ERR_STREAM_CLOSED;
}
if (stream->state == NGHTTP2_STREAM_CLOSING) {
return NGHTTP2_ERR_STREAM_CLOSING;
}
return 0;
}