Fix crash when player leaves

This commit is contained in:
Li 2022-09-05 15:13:14 +12:00
parent ed721b362e
commit 4b48db6b2a
5 changed files with 13 additions and 9 deletions

View file

@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")] // [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.7.140.0")] [assembly: AssemblyVersion("1.8.1.0")]
[assembly: AssemblyFileVersion("1.7.140.0")] [assembly: AssemblyFileVersion("1.8.1.0")]

View file

@ -1,5 +1,5 @@
Package: hisp Package: hisp
Version: 1.7.140 Version: 1.8.1
Depends: coreutils,systemd,mariadb-server,libsqlite3-dev,zlib1g-dev,libicu-dev,libkrb5-dev Depends: coreutils,systemd,mariadb-server,libsqlite3-dev,zlib1g-dev,libicu-dev,libkrb5-dev
Maintainer: Li Maintainer: Li
Homepage: https://islehorse.com Homepage: https://islehorse.com

View file

@ -30,8 +30,8 @@ using System.Runtime.InteropServices;
// //
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
[assembly: AssemblyVersion("1.7.140.0")] [assembly: AssemblyVersion("1.8.1.0")]
[assembly: AssemblyFileVersion("1.7.140.0")] [assembly: AssemblyFileVersion("1.8.1.0")]

View file

@ -117,8 +117,12 @@ namespace HISP.Server
do do
{ {
Socket eSocket = e.AcceptSocket; Socket eSocket = e.AcceptSocket;
if(eSocket != null) if (eSocket == null)
new GameClient(eSocket); return;
if (eSocket.RemoteEndPoint == null)
return;
new GameClient(eSocket);
e.AcceptSocket = null; e.AcceptSocket = null;
if(GameServer.ServerSocket == null) if(GameServer.ServerSocket == null)

View file

@ -30,8 +30,8 @@ using System.Runtime.InteropServices;
// //
// You can specify all the values or you can default the Build and Revision Numbers // You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below: // by using the '*' as shown below:
[assembly: AssemblyVersion("1.7.140.0")] [assembly: AssemblyVersion("1.8.1.0")]
[assembly: AssemblyFileVersion("1.7.140.0")] [assembly: AssemblyFileVersion("1.8.1.0")]