Update doc
This commit is contained in:
parent
a3fa257473
commit
85671a69bf
|
@ -51,6 +51,7 @@
|
|||
/* Exported for unit test */
|
||||
#define NGHTTP2_STATIC_TABLE_LENGTH 61
|
||||
|
||||
/* Generated by genlibtokenlookup.py */
|
||||
typedef enum {
|
||||
NGHTTP2_TOKEN__AUTHORITY = 0,
|
||||
NGHTTP2_TOKEN__METHOD = 1,
|
||||
|
|
|
@ -2244,12 +2244,17 @@ static int session_close_stream_on_goaway(nghttp2_session *session,
|
|||
static void session_outbound_item_schedule(nghttp2_session *session,
|
||||
nghttp2_outbound_item *item,
|
||||
int32_t weight) {
|
||||
/* Schedule next write. Offset proportional to the write size.
|
||||
Stream with heavier weight is scheduled earlier. */
|
||||
size_t delta = item->frame.hd.length * NGHTTP2_MAX_WEIGHT / weight;
|
||||
|
||||
if (session->last_cycle < item->cycle) {
|
||||
session->last_cycle = item->cycle;
|
||||
}
|
||||
|
||||
/* We pretend to ignore overflow given that the value range of
|
||||
item->cycle, which is uint64_t. nghttp2 won't explode even when
|
||||
overflow occurs, there might be some disturbance of priority. */
|
||||
item->cycle = session->last_cycle + delta;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue