diff options
author | madmaxoft <github@xoft.cz> | 2013-08-14 19:56:29 +0200 |
---|---|---|
committer | madmaxoft <github@xoft.cz> | 2013-08-14 19:56:29 +0200 |
commit | e2ff4a2e5c654e1c4c33f5a9098bef35e0755897 (patch) | |
tree | 970e2d76249437f90b27291b4e8795b77aa08aa5 | |
parent | Fixed wrong names for some metas. (diff) | |
download | cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar.gz cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar.bz2 cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar.lz cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar.xz cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.tar.zst cuberite-e2ff4a2e5c654e1c4c33f5a9098bef35e0755897.zip |
-rw-r--r-- | source/World.cpp | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/source/World.cpp b/source/World.cpp index 59240c7da..5c3a24177 100644 --- a/source/World.cpp +++ b/source/World.cpp @@ -552,6 +552,17 @@ void cWorld::Start(void) void cWorld::Stop(void) { + // Delete the clients that have been in this world: + { + cCSLock Lock(m_CSClients); + for (cClientHandleList::iterator itr = m_Clients.begin(); itr != m_Clients.end(); ++itr) + { + (*itr)->Destroy(); + delete *itr; + } // for itr - m_Clients[] + m_Clients.clear(); + } + m_TickThread.Stop(); m_Lighting.Stop(); m_Generator.Stop(); |