Skip to content

Commit

Permalink
* ext/socket/ancdata.c (bsock_recvmsg_internal): stretch the buffer size
Browse files Browse the repository at this point in the history
  when EMSGSIZE occurs on non HAVE_STRUCT_MSGHDR_MSG_CONTROL platforms
  (such as, Windows).  fixes a test error revealed by r52625.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@52631 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
  • Loading branch information
unak committed Nov 18, 2015
1 parent ca5f587 commit d8e1939
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 0 deletions.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
Wed Nov 18 10:33:06 2015 NAKAMURA Usaku <usa@ruby-lang.org>

* ext/socket/ancdata.c (bsock_recvmsg_internal): stretch the buffer size
when EMSGSIZE occurs on non HAVE_STRUCT_MSGHDR_MSG_CONTROL platforms
(such as, Windows). fixes a test error revealed by r52625.

Wed Nov 18 10:12:36 2015 Eric Wong <e@80x24.org>

* ext/socket/ancdata.c (bsock_recvmsg_internal): use 4096 as
Expand Down
4 changes: 4 additions & 0 deletions ext/socket/ancdata.c
Original file line number Diff line number Diff line change
Expand Up @@ -1570,6 +1570,10 @@ bsock_recvmsg_internal(VALUE sock,
gc_done = 1;
goto retry;
}
#else
if (grow_buffer && errno == EMSGSIZE)
ss = (ssize_t)iov.iov_len;
else
#endif
rb_sys_fail("recvmsg(2)");
}
Expand Down

0 comments on commit d8e1939

Please sign in to comment.