summaryrefslogtreecommitdiffstats
path: root/src/ClientHandle.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/ClientHandle.cpp')
-rw-r--r--src/ClientHandle.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/ClientHandle.cpp b/src/ClientHandle.cpp
index 143d5df03..01d85fee8 100644
--- a/src/ClientHandle.cpp
+++ b/src/ClientHandle.cpp
@@ -104,7 +104,10 @@ cClientHandle::~cClientHandle()
{
ASSERT(m_State == eState::csDestroyed); // Has Destroy() been called?
- if (m_Player != nullptr)
+ if (
+ !cRoot::Get()->GetServer()->IsShuttingDown() && // If server is shutting down, m_Player is considered invalid. It will be cleaned up by cWorld
+ (m_Player != nullptr)
+ )
{
cWorld * World = m_Player->GetWorld();