mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
sitä sun tätä tekeillä, toimii kivasti
This commit is contained in:
parent
e8fd5eb8ee
commit
c707e00195
19 changed files with 998 additions and 761 deletions
|
@ -164,7 +164,9 @@ void UDPSocket::Bind(unsigned short port)
|
|||
|
||||
if(bind(m_handle, (const sockaddr*)&address, sizeof(sockaddr_in)) < 0)
|
||||
{
|
||||
#ifndef DISABLE_ERRNO
|
||||
dstream<<(int)m_handle<<": Bind failed: "<<strerror(errno)<<std::endl;
|
||||
#endif
|
||||
throw SocketException("Failed to bind socket");
|
||||
}
|
||||
}
|
||||
|
@ -291,7 +293,9 @@ bool UDPSocket::WaitData(int timeout_ms)
|
|||
}
|
||||
else if(result < 0){
|
||||
// Error
|
||||
#ifndef DISABLE_ERRNO
|
||||
dstream<<(int)m_handle<<": Select failed: "<<strerror(errno)<<std::endl;
|
||||
#endif
|
||||
#ifdef _WIN32
|
||||
dstream<<(int)m_handle<<": WSAGetLastError()="<<WSAGetLastError()<<std::endl;
|
||||
#endif
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue