mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
Merge pull request #5840 from mattn/errno-windows
errno must be set before mrb_sys_fail
This commit is contained in:
@@ -1269,7 +1269,8 @@ retry:
|
||||
n = select(max, rp, wp, ep, tp);
|
||||
if (n < 0) {
|
||||
#ifdef _WIN32
|
||||
if (WSAGetLastError() != WSAEINTR)
|
||||
errno = WSAGetLastError();
|
||||
if (errno != WSAEINTR)
|
||||
mrb_sys_fail(mrb, "select failed");
|
||||
#else
|
||||
if (errno != EINTR)
|
||||
|
||||
Reference in New Issue
Block a user