Mercurial > hg > nginx
changeset 5252:982678c5c270
Valgrind: another complaint about uninitialized bytes.
author | Tatsuhiko Kubo <cubicdaiya@gmail.com> |
---|---|
date | Wed, 12 Jun 2013 00:41:24 +0900 |
parents | 4ef49081ef4c |
children | a82f305487c2 |
files | src/os/unix/ngx_channel.c |
diffstat | 1 files changed, 2 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/src/os/unix/ngx_channel.c Thu Jun 13 16:28:42 2013 +0400 +++ b/src/os/unix/ngx_channel.c Wed Jun 12 00:41:24 2013 +0900 @@ -34,6 +34,8 @@ msg.msg_control = (caddr_t) &cmsg; msg.msg_controllen = sizeof(cmsg); + ngx_memzero(&cmsg, sizeof(cmsg)); + cmsg.cm.cmsg_len = CMSG_LEN(sizeof(int)); cmsg.cm.cmsg_level = SOL_SOCKET; cmsg.cm.cmsg_type = SCM_RIGHTS;