mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
clear cmsg padding.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12220 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
e3b9378f38
commit
24af397fcd
1 changed files with 1 additions and 0 deletions
|
@ -1942,6 +1942,7 @@ unix_send_io(VALUE sock, VALUE val)
|
|||
msg.msg_control = (caddr_t)&cmsg;
|
||||
msg.msg_controllen = CMSG_LEN(sizeof(int));
|
||||
msg.msg_flags = 0;
|
||||
MEMZERO((char*)&cmsg, char, sizeof(cmsg));
|
||||
cmsg.hdr.cmsg_len = CMSG_LEN(sizeof(int));
|
||||
cmsg.hdr.cmsg_level = SOL_SOCKET;
|
||||
cmsg.hdr.cmsg_type = SCM_RIGHTS;
|
||||
|
|
Loading…
Add table
Reference in a new issue