mirror of
https://github.com/libretro/RetroArch
synced 2025-03-24 13:43:32 +00:00
Handle errors.
This commit is contained in:
parent
0b729e1707
commit
b01fc8b4f7
@ -31,7 +31,7 @@ static bool socket_nonblock(int fd)
|
|||||||
{
|
{
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
u_long mode = 1;
|
u_long mode = 1;
|
||||||
ioctlsocket(fd, FIONBIO, &mode);
|
return ioctlsocket(fd, FIONBIO, &mode) == 0;
|
||||||
#else
|
#else
|
||||||
return fcntl(fd, F_SETFL, fcntl(fd, F_GETFL) | O_NONBLOCK) == 0;
|
return fcntl(fd, F_SETFL, fcntl(fd, F_GETFL) | O_NONBLOCK) == 0;
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user