1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

ext/socket/ancdata.c (bsock_recvmsg_internal): GC guard

The control buffer may be used throughout the function, so
prevent the string from being lost to GC.

* ext/socket/ancdata.c (bsock_recvmsg_internal): GC guard
  [Bug #11123]

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@50449 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
normal 2015-05-08 22:31:02 +00:00
parent fb684ba4c2
commit c3d826bb2b
2 changed files with 6 additions and 0 deletions

View file

@ -1,3 +1,8 @@
Sat May 9 06:48:36 2015 Eric Wong <e@80x24.org>
* ext/socket/ancdata.c (bsock_recvmsg_internal): GC guard
[Bug #11123]
Fri May 8 22:57:24 2015 takiy33 <takiy33@gmail.com>
* test/matrix/test_matrix.rb (test_determinant): refactor test on

View file

@ -1711,6 +1711,7 @@ bsock_recvmsg_internal(int argc, VALUE *argv, VALUE sock, int nonblock)
discard_cmsg(cmh, msg_end, (flags & MSG_PEEK) != 0);
rb_ary_push(ret, ctl);
}
RB_GC_GUARD(ctl_str);
}
#endif