diff --git a/lib/nghttp2_session.c b/lib/nghttp2_session.c index 5ef2b746..bdf282ec 100644 --- a/lib/nghttp2_session.c +++ b/lib/nghttp2_session.c @@ -5881,16 +5881,12 @@ int nghttp2_session_want_read(nghttp2_session *session) { } int nghttp2_session_want_write(nghttp2_session *session) { - size_t num_active_streams; - /* If these flag is set, we don't want to write any data. The application should drop the connection. */ if (session->goaway_flags & NGHTTP2_GOAWAY_TERM_SENT) { return 0; } - num_active_streams = session_get_num_active_streams(session); - /* * Unless termination GOAWAY is sent or received, we want to write * frames if there is pending ones. If pending frame is request/push @@ -5906,10 +5902,6 @@ int nghttp2_session_want_write(nghttp2_session *session) { return 0; } - if (num_active_streams > 0) { - return 1; - } - /* If there is no active streams and GOAWAY has been sent or received, we are done with this session. */ return (session->goaway_flags &