diff options
author | tradke <tradke@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 2002-01-18 16:06:47 +0000 |
---|---|---|
committer | tradke <tradke@b589c3ab-70e8-4b4d-a09f-cba2dd200880> | 2002-01-18 16:06:47 +0000 |
commit | 43701e2482f1e66f483ec79169737c575b1759ea (patch) | |
tree | 4d8c81137f7c5e48dded9c83688b871a528ba003 /src/OutputInfo.c | |
parent | d7fe8a33f2937629e7967b7a2eae998c40dd8e68 (diff) |
Fixed small memory leak.
git-svn-id: http://svn.cactuscode.org/arrangements/CactusBase/IOBasic/trunk@112 b589c3ab-70e8-4b4d-a09f-cba2dd200880
Diffstat (limited to 'src/OutputInfo.c')
-rw-r--r-- | src/OutputInfo.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/OutputInfo.c b/src/OutputInfo.c index 96af228..d737375 100644 --- a/src/OutputInfo.c +++ b/src/OutputInfo.c @@ -579,7 +579,7 @@ static void PrintHeader (iobasicGH *myGH, int num_vars) { DECLARE_CCTK_PARAMETERS int i, num_columns, vindex; - char *fullname, *msg; + char *fullname, *msg, *oldmsg; iobasic_reduction_t *reduction; @@ -601,7 +601,9 @@ static void PrintHeader (iobasicGH *myGH, int num_vars) } else { - Util_asprintf (&msg, "%s %s", msg, fullname); + oldmsg = msg; + Util_asprintf (&msg, "%s %s", oldmsg, fullname); + free (oldmsg); } free (fullname); } |