diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-03-04 19:40:48 +0100 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2013-03-04 19:40:48 +0100 |
commit | eb68b7ce0157fd55b7d50cca956986d0fdb60bd1 (patch) | |
tree | c0aa246374d5dcb034b4652ea937fc0a5478c67b /source/OSSupport/SocketThreads.cpp | |
parent | Player can sit in minecarts (but not move them yet) (diff) | |
download | cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar.gz cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar.bz2 cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar.lz cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar.xz cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.tar.zst cuberite-eb68b7ce0157fd55b7d50cca956986d0fdb60bd1.zip |
Diffstat (limited to '')
-rw-r--r-- | source/OSSupport/SocketThreads.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/source/OSSupport/SocketThreads.cpp b/source/OSSupport/SocketThreads.cpp index 5058f3313..943293f5c 100644 --- a/source/OSSupport/SocketThreads.cpp +++ b/source/OSSupport/SocketThreads.cpp @@ -433,11 +433,7 @@ bool cSocketThreads::cSocketThread::Start(void) LOGERROR("Cannot create a Control socket for a cSocketThread (\"%s\"); continuing, but server may be unreachable from now on.", cSocket::GetLastErrorString().c_str()); return false; } - cSocket::SockAddr_In Addr; - Addr.Family = cSocket::ADDRESS_FAMILY_INTERNET; - Addr.Address = cSocket::INTERNET_ADDRESS_LOCALHOST(); - Addr.Port = 0; // Any free port is okay - if (m_ControlSocket2.Bind(Addr) != 0) + if (m_ControlSocket2.BindToLocalhost(cSocket::ANY_PORT) != 0) { LOGERROR("Cannot bind a Control socket for a cSocketThread (\"%s\"); continuing, but server may be unreachable from now on.", cSocket::GetLastErrorString().c_str()); m_ControlSocket2.CloseSocket(); |