]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - cl_demo.c
VM_sprintf: use intmax_t for integer types
[xonotic/darkplaces.git] / cl_demo.c
index 5ca4780ee4cdc8ac950572290db37f7b58c07e54..1584cb7bf19e59f462b4390be656e0637a5c7a97 100644 (file)
--- a/cl_demo.c
+++ b/cl_demo.c
@@ -510,7 +510,7 @@ static void CL_FinishTimeDemo (void)
                {
                        static benchmarkhistory_t *history = NULL;
                        if(!history)
-                               history = Z_Malloc(sizeof(*history) * atoi(com_argv[i + 1]));
+                               history = (benchmarkhistory_t *)Z_Malloc(sizeof(*history) * atoi(com_argv[i + 1]));
 
                        history[benchmark_runs - 1].frames = frames;
                        history[benchmark_runs - 1].time = time;
@@ -609,6 +609,5 @@ void CL_TimeDemo_f (void)
        cls.timedemo = true;
        cls.td_frames = -2;             // skip the first frame
        cls.demonum = -1;               // stop demo loop
-       cls.demonum = -1;               // stop demo loop
 }