From b5957b35b6bfcec3e10b26d2a87df45e6a6f27e0 Mon Sep 17 00:00:00 2001 From: tradke Date: Fri, 18 Jan 2002 16:07:08 +0000 Subject: Fixed small memory leak. git-svn-id: http://svn.cactuscode.org/arrangements/CactusIO/IOJpeg/trunk@53 eff87b29-5268-4891-90a3-a07138403961 --- src/Output2D.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/Output2D.c b/src/Output2D.c index 9c8a8e4..cc58789 100644 --- a/src/Output2D.c +++ b/src/Output2D.c @@ -187,7 +187,7 @@ int IOJpeg_TriggerOutput2D (const cGH *GH, int vindex) static void CheckSteerableParameters (IOJpegGH *myGH) { int i, out_old, out2D_vars_current_nset; - char *msg, *fullname; + char *msg, *oldmsg, *fullname; static int out2D_vars_lastset = 0; DECLARE_CCTK_PARAMETERS @@ -240,7 +240,9 @@ static void CheckSteerableParameters (IOJpegGH *myGH) } else { - Util_asprintf (&msg, "%s %s", msg, fullname); + oldmsg = msg; + Util_asprintf (&msg, "%s %s", oldmsg, fullname); + free (oldmsg); } free (fullname); } -- cgit v1.2.3