From db474201202f8617e3d28608b071d1e7b8cad133 Mon Sep 17 00:00:00 2001 From: Thomas Schmitt Date: Tue, 3 Nov 2015 12:57:37 +0000 Subject: [PATCH] Closed a memory leak with message sieve. Coverity CID 28739. --- xorriso/text_io.c | 2 ++ xorriso/xorriso_timestamp.h | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/xorriso/text_io.c b/xorriso/text_io.c index 6253cba6..4637d765 100644 --- a/xorriso/text_io.c +++ b/xorriso/text_io.c @@ -2198,6 +2198,8 @@ int Xorriso_sieve_filter_msg(struct XorrisO *xorriso, char *msg, int flag) if(strncmp(prefix, msg, strlen(prefix)) != 0) continue; + if (to_parse != NULL) + free(to_parse); to_parse= strdup(msg); if(to_parse == NULL) goto no_mem; diff --git a/xorriso/xorriso_timestamp.h b/xorriso/xorriso_timestamp.h index a8ab0b9b..7c32ed36 100644 --- a/xorriso/xorriso_timestamp.h +++ b/xorriso/xorriso_timestamp.h @@ -1 +1 @@ -#define Xorriso_timestamP "2015.11.03.125130" +#define Xorriso_timestamP "2015.11.03.125655"