mirror of
https://github.com/BeamMP/BeamMP-Server.git
synced 2026-04-19 22:50:19 +00:00
possibly fixed UDPSend error on unix
This commit is contained in:
@@ -58,10 +58,14 @@ void UDPSend(Client* c, std::string Data) {
|
|||||||
c->SetStatus(-1);
|
c->SetStatus(-1);
|
||||||
}
|
}
|
||||||
#else // unix
|
#else // unix
|
||||||
if (sendOk != 0) {
|
if (sendOk == -1) {
|
||||||
debug(Sec("(UDP) Send Failed Code : ") + std::string(strerror(errno)));
|
debug(Sec("(UDP) Send Failed Code : ") + std::string(strerror(errno)));
|
||||||
if (c->GetStatus() > -1)
|
if (c->GetStatus() > -1)
|
||||||
c->SetStatus(-1);
|
c->SetStatus(-1);
|
||||||
|
} else if (sendOk == 0) {
|
||||||
|
debug(Sec("(UDP) sendto returned 0"));
|
||||||
|
if (c->GetStatus() > -1)
|
||||||
|
c->SetStatus(-1);
|
||||||
}
|
}
|
||||||
#endif // WIN32
|
#endif // WIN32
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user