Fix bug for platform which does not have SOCK_NONBLOCK
This commit is contained in:
parent
3162ffedfc
commit
7d87221a8c
|
@ -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