We can assert this

This commit is contained in:
Tatsuhiro Tsujikawa 2015-04-16 22:41:00 +09:00
parent d4a22edeb3
commit e6ad2eb14f
1 changed files with 3 additions and 1 deletions

View File

@ -2246,7 +2246,9 @@ static void session_outbound_item_schedule(nghttp2_session *session,
int32_t weight) {
size_t delta = item->frame.hd.length * NGHTTP2_MAX_WEIGHT / weight;
session->last_cycle = nghttp2_max(session->last_cycle, item->cycle);
assert(session->last_cycle <= item->cycle);
session->last_cycle = item->cycle;
item->cycle = session->last_cycle + delta;
}