a tester sur Linux (rien change sur windows)

This commit is contained in:
MarcEricMartel 2023-10-29 16:43:09 -04:00
parent 53ed811936
commit e2dbf52b17

View File

@ -57,7 +57,11 @@ int Connector::Connect(const char* srv_addr, std::string name) {
return 2;
}
#ifdef _WIN32
u_long flag = 1;
#else
uint64_t** flag = nullptr;
#endif
if (ioctl(m_sock_tcp, SOCK_NONBLOCK, &flag) < 0) {
std::cout << "Impossible de mettre le socket en mode non-bloquant." << std::endl;
return 3;