add macos MPNoobs build task

This commit is contained in:
Li 2022-10-04 15:59:42 +13:00
parent a50d052c2a
commit 663106ca34
6 changed files with 32 additions and 18 deletions

View file

@ -120,21 +120,26 @@ namespace HISP.Server
}
public static void CreateClient(object sender, SocketAsyncEventArgs e)
{
try{
do
{
Socket eSocket = e.AcceptSocket;
try
{
do
{
Socket eSocket = e.AcceptSocket;
if (GameServer.ServerSocket == null)
return;
if (eSocket == null)
continue;
return;
if (eSocket.RemoteEndPoint == null)
continue;
new GameClient(eSocket);
e.AcceptSocket = null;
if(GameServer.ServerSocket == null)
return;
} while (!GameServer.ServerSocket.AcceptAsync(e));
}catch(ObjectDisposedException) {} // server shutdown
e.AcceptSocket = null;
if (GameServer.ServerSocket == null)
return;
} while (!GameServer.ServerSocket.AcceptAsync(e));
}
catch (ObjectDisposedException) { } // server shutdown
}
private void timeoutTimerTick(object state)
{