QUIC: moved a variable initialization near to its use.
This tends to produce slightly more optimal code with pos == NULL when built with Clang on low optimization levels. Spotted by Ruslan Ermilov.
This commit is contained in:
parent
6e1487496d
commit
7b5283b003
1 changed files with 2 additions and 2 deletions
|
@ -1967,8 +1967,6 @@ ngx_quic_create_transport_params(u_char *pos, u_char *end, ngx_quic_tp_t *tp,
|
|||
p = ngx_cpymem(p, value.data, value.len); \
|
||||
} while (0)
|
||||
|
||||
p = pos;
|
||||
|
||||
len = ngx_quic_tp_len(NGX_QUIC_TP_INITIAL_MAX_DATA, tp->initial_max_data);
|
||||
|
||||
len += ngx_quic_tp_len(NGX_QUIC_TP_INITIAL_MAX_STREAMS_UNI,
|
||||
|
@ -2026,6 +2024,8 @@ ngx_quic_create_transport_params(u_char *pos, u_char *end, ngx_quic_tp_t *tp,
|
|||
return len;
|
||||
}
|
||||
|
||||
p = pos;
|
||||
|
||||
ngx_quic_tp_vint(NGX_QUIC_TP_INITIAL_MAX_DATA,
|
||||
tp->initial_max_data);
|
||||
|
||||
|
|
Loading…
Reference in a new issue