]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
move the mutex creation to after the memory pool is created
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 23 Oct 2011 22:52:27 +0000 (22:52 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 23 Oct 2011 22:52:27 +0000 (22:52 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@11467 d7cf8633-e32d-0410-b094-e92efae38249

zone.c

diff --git a/zone.c b/zone.c
index 87e7121248bf6cd0043cdf69156dfffa75dd1a52..02920535287b75970eaf7f258849f75cd2204748 100644 (file)
--- a/zone.c
+++ b/zone.c
@@ -874,13 +874,13 @@ void Memory_Init (void)
        u.s = 0x100;
        mem_bigendian = u.b[0] != 0;
 
-       if (Thread_HasThreads())
-               mem_mutex = Thread_CreateMutex();
-
        sentinel_seed = rand();
        poolchain = NULL;
        tempmempool = Mem_AllocPool("Temporary Memory", POOLFLAG_TEMP, NULL);
        zonemempool = Mem_AllocPool("Zone", 0, NULL);
+
+       if (Thread_HasThreads())
+               mem_mutex = Thread_CreateMutex();
 }
 
 void Memory_Shutdown (void)