aboutsummaryrefslogtreecommitdiffstats
path: root/common/stringhelp.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/stringhelp.c')
-rw-r--r--common/stringhelp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/common/stringhelp.c b/common/stringhelp.c
index 0e96c9e54..95912e0b2 100644
--- a/common/stringhelp.c
+++ b/common/stringhelp.c
@@ -538,6 +538,7 @@ do_make_filename (int xmode, const char *first_part, va_list arg_ptr)
home_buffer = xtrymalloc (n);
if (!home_buffer)
{
+ xfree (home);
xfree (name);
return NULL;
}
@@ -556,6 +557,7 @@ do_make_filename (int xmode, const char *first_part, va_list arg_ptr)
else
strcpy (stpcpy (stpcpy (p, home), "/"), name);
+ xfree (home);
xfree (name);
name = home_buffer;
/* Let's do a simple compression to catch the most common