1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00

x.net: fix new_tcp_socket()

This commit is contained in:
Alexander Medvednikov
2020-08-24 03:23:57 +02:00
parent fa8f5df817
commit 702a80fc5a
3 changed files with 5 additions and 3 deletions

View File

@ -273,8 +273,8 @@ fn new_tcp_socket() ?TcpSocket {
s := TcpSocket {
handle: sockfd
}
s.set_option_bool(.reuse_addr, true)?
//s.set_option_int(.reuse_addr, 1)?
//s.set_option_bool(.reuse_addr, true)?
s.set_option_int(.reuse_addr, 1)?
$if windows {
t := true
socket_error(C.ioctlsocket(sockfd, fionbio, &t))?