summaryrefslogtreecommitdiffstats
path: root/src/erec.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/erec.c')
-rw-r--r--src/erec.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/erec.c b/src/erec.c
index eacdd97a..439add97 100644
--- a/src/erec.c
+++ b/src/erec.c
@@ -39,6 +39,8 @@ static void input_descriptor_destroy(const struct input_descriptor *indesc)
indesc->location.indesc->type != INDESC_INTERNAL) {
input_descriptor_destroy(indesc->location.indesc);
}
+ if (indesc->name)
+ xfree(indesc->name);
xfree(indesc);
}
@@ -53,6 +55,9 @@ static struct input_descriptor *input_descriptor_dup(const struct input_descript
indesc->location.indesc->type != INDESC_INTERNAL)
dup_indesc->location.indesc = input_descriptor_dup(indesc->location.indesc);
+ if (indesc->name)
+ dup_indesc->name = xstrdup(indesc->name);
+
return dup_indesc;
}