Move the parse of session->ob_reg after session->ob_syn.

This commit is contained in:
Yang Song 2019-02-21 15:12:46 -05:00
parent f5feb16ef4
commit 5bf12b24f9
1 changed files with 7 additions and 7 deletions

View File

@ -2349,13 +2349,6 @@ nghttp2_session_pop_next_ob_item(nghttp2_session *session) {
return item;
}
item = nghttp2_outbound_queue_top(&session->ob_reg);
if (item) {
nghttp2_outbound_queue_pop(&session->ob_reg);
item->queued = 0;
return item;
}
if (!session_is_outgoing_concurrent_streams_max(session)) {
item = nghttp2_outbound_queue_top(&session->ob_syn);
if (item) {
@ -2365,6 +2358,13 @@ nghttp2_session_pop_next_ob_item(nghttp2_session *session) {
}
}
item = nghttp2_outbound_queue_top(&session->ob_reg);
if (item) {
nghttp2_outbound_queue_pop(&session->ob_reg);
item->queued = 0;
return item;
}
if (session->remote_window_size > 0) {
return nghttp2_stream_next_outbound_item(&session->root);
}