Fix bug for platform which does not have SOCK_NONBLOCK
This commit is contained in:
parent
4bc7710de9
commit
acb661df72
|
@ -953,7 +953,7 @@ int create_nonblock_udp_socket(int family) {
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
#else // !SOCK_NONBLOCK
|
#else // !SOCK_NONBLOCK
|
||||||
auto fd = socket(family, SOCK_STREAM, 0);
|
auto fd = socket(family, SOCK_DGRAM, 0);
|
||||||
|
|
||||||
if (fd == -1) {
|
if (fd == -1) {
|
||||||
return -1;
|
return -1;
|
||||||
|
|
Loading…
Reference in New Issue