]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
sys_usetimegettime is now initialized at a place where it shouldn't crash anymore...
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 20 Aug 2002 02:50:38 +0000 (02:50 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Tue, 20 Aug 2002 02:50:38 +0000 (02:50 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2259 d7cf8633-e32d-0410-b094-e92efae38249

host.c
sys_shared.c
sys_win.c

diff --git a/host.c b/host.c
index 20d22b8b3a90a4d6a634017331a6aee91b50e327..5d570becb6c0d0231bcef2af9ae83a7354405a44 100644 (file)
--- a/host.c
+++ b/host.c
@@ -817,7 +817,6 @@ void Host_Init (void)
                developer.value = 1;
        }
 
-       Memory_Init ();
        Cmd_Init ();
        Memory_Init_Commands();
        R_Modules_Init();
index 0753133c0c6c0b3174f14093d7f312cf30f012c2..370752bfd3d509d242e6dc862a964ff694b56c56 100644 (file)
@@ -106,6 +106,8 @@ char engineversion[128];
 
 void Sys_Shared_EarlyInit(void)
 {
+       Memory_Init ();
+
 #if defined(__linux__)
        sprintf (engineversion, "%s Linux %s", gamename, buildstring);
 #elif defined(WIN32)
index 1479e7c8f9a7ab8a5cdc8fb6a78283a2d0b98bdf..151565564a33cbcccd3ddc51cf212ee742a2199e 100644 (file)
--- a/sys_win.c
+++ b/sys_win.c
@@ -484,8 +484,6 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin
        if (hPrevInstance)
                return 0;
 
-       Cvar_RegisterVariable(&sys_usetimegettime);
-
        global_hInstance = hInstance;
        global_nCmdShow = nCmdShow;
 
@@ -536,6 +534,8 @@ int WINAPI WinMain (HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLin
 
        Sys_Shared_EarlyInit();
 
+       Cvar_RegisterVariable(&sys_usetimegettime);
+
        tevent = CreateEvent(NULL, false, false, NULL);
 
        if (!tevent)