]> git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
fix a couple error messages on shutdown of dedicated server
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 21 Nov 2010 12:34:31 +0000 (12:34 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 21 Nov 2010 12:34:31 +0000 (12:34 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@10623 d7cf8633-e32d-0410-b094-e92efae38249

console.c

index ccdd38da2f1554dff9e64e798071eb25a75a459c..0eaccd3efb4a43914d6eb5342a973e57a08d4c19 100644 (file)
--- a/console.c
+++ b/console.c
@@ -126,8 +126,10 @@ ConBuffer_Shutdown
 void ConBuffer_Shutdown(conbuffer_t *buf)
 {
        buf->active = false;
-       Mem_Free(buf->text);
-       Mem_Free(buf->lines);
+       if (buf->text)
+               Mem_Free(buf->text);
+       if (buf->lines)
+               Mem_Free(buf->lines);
        buf->text = NULL;
        buf->lines = NULL;
 }