vita: Enable nonblock TCP socket

This commit is contained in:
Sunguk Lee 2019-11-04 02:43:05 +09:00
parent 49fd1bed3f
commit 021a1b23e9
No known key found for this signature in database
GPG Key ID: 20A74A5D37EEA757

View File

@ -178,7 +178,9 @@ SOCKET bindUdpSocket(int addrfamily, int bufferSize) {
}
int setSocketNonBlocking(SOCKET s, int val) {
#ifdef FIONBIO
#if defined(__vita__)
return setsockopt(s, SOL_SOCKET, SO_NONBLOCK, (char*)&val, sizeof(val));
#elif defined(FIONBIO)
return ioctlsocket(s, FIONBIO, &val);
#else
return SOCKET_ERROR;