From 902f15c0093254399a8186d67688a1df3fc55a74 Mon Sep 17 00:00:00 2001 From: divverent Date: Sat, 9 Aug 2008 06:38:22 +0000 Subject: [PATCH] fix double free in qcstatus git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@8441 d7cf8633-e32d-0410-b094-e92efae38249 --- netconn.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/netconn.c b/netconn.c index 3abc226d..d5ecaf99 100755 --- a/netconn.c +++ b/netconn.c @@ -1958,7 +1958,10 @@ static qboolean NetConn_BuildStatusResponse(const char* challenge, char* out_msg fullstatus ? "\n" : ""); if(qcstatus) + { Mem_Free((char *)qcstatus); + qcstatus = NULL; + } // Make sure it fits in the buffer if (length < 0) @@ -2026,6 +2029,7 @@ static qboolean NetConn_BuildStatusResponse(const char* challenge, char* out_msg pingvalue, cleanname); Mem_Free((char *)qcstatus); + qcstatus = NULL; } else length = dpsnprintf(ptr, left, "%d %d \"%s\"\n", -- 2.39.2