UNIDIRECTIONAL handling when SYN_REPLY and HEADERS are received.
This commit is contained in:
parent
d1c4c59aad
commit
0ecf581e63
|
@ -686,7 +686,7 @@ int spdylay_session_on_syn_reply_received(spdylay_session *session,
|
|||
if(spdylay_session_is_my_stream_id(session, frame->syn_reply.stream_id)) {
|
||||
spdylay_stream *stream = spdylay_session_get_stream
|
||||
(session, frame->syn_reply.stream_id);
|
||||
if(stream) {
|
||||
if(stream && (stream->flags & SPDYLAY_FLAG_UNIDIRECTIONAL) == 0) {
|
||||
if(stream->state == SPDYLAY_STREAM_OPENING) {
|
||||
valid = 1;
|
||||
stream->state = SPDYLAY_STREAM_OPENED;
|
||||
|
@ -782,6 +782,9 @@ int spdylay_session_on_headers_received(spdylay_session *session,
|
|||
if(frame->headers.hd.flags & SPDYLAY_FLAG_FIN) {
|
||||
stream->flags |= SPDYLAY_FLAG_FIN;
|
||||
}
|
||||
if(stream->flags & SPDYLAY_FLAG_UNIDIRECTIONAL) {
|
||||
spdylay_session_close_stream(session, frame->headers.stream_id);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue