mirror of
https://github.com/nginx/nginx.git
synced 2026-05-13 17:46:53 +00:00
Restored zeroing of ngx_channel_t in ngx_pass_open_channel().
Due to structure's alignment, some uninitialized memory contents may have been passed between processes. Zeroing was removed in 0215ec9aaa8a. Reported by Johnny Wang.
This commit is contained in:
parent
7b9920aad8
commit
f02e2a734e
1 changed files with 2 additions and 0 deletions
|
|
@ -398,6 +398,8 @@ ngx_pass_open_channel(ngx_cycle_t *cycle)
|
|||
ngx_int_t i;
|
||||
ngx_channel_t ch;
|
||||
|
||||
ngx_memzero(&ch, sizeof(ngx_channel_t));
|
||||
|
||||
ch.command = NGX_CMD_OPEN_CHANNEL;
|
||||
ch.pid = ngx_processes[ngx_process_slot].pid;
|
||||
ch.slot = ngx_process_slot;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue