зеркало из https://github.com/github/ruby.git
* ext/socket/ancdata.c (bsock_sendmsg_internal): controls_num should
not be negative. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@40626 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
bfb334eefa
Коммит
2ffbe0345d
|
@ -1,3 +1,8 @@
|
|||
Thu May 9 22:00:35 2013 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* ext/socket/ancdata.c (bsock_sendmsg_internal): controls_num should
|
||||
not be negative.
|
||||
|
||||
Thu May 9 21:09:57 2013 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* file.c, ext/etc/etc.c, ext/socket/unixsocket.c,
|
||||
|
|
|
@ -1153,7 +1153,7 @@ bsock_sendmsg_internal(int argc, VALUE *argv, VALUE sock, int nonblock)
|
|||
data = argv[0];
|
||||
if (1 < argc) vflags = argv[1];
|
||||
if (2 < argc) dest_sockaddr = argv[2];
|
||||
controls_num = argc - 3;
|
||||
controls_num = 3 < argc ? argc - 3 : 0;
|
||||
#if defined(HAVE_STRUCT_MSGHDR_MSG_CONTROL)
|
||||
if (3 < argc) { controls_ptr = &argv[3]; }
|
||||
#endif
|
||||
|
|
Загрузка…
Ссылка в новой задаче