summaryrefslogtreecommitdiff
path: root/libfshelp/translator-list.c
diff options
context:
space:
mode:
Diffstat (limited to 'libfshelp/translator-list.c')
-rw-r--r--libfshelp/translator-list.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libfshelp/translator-list.c b/libfshelp/translator-list.c
index 99a858f4..87dcb211 100644
--- a/libfshelp/translator-list.c
+++ b/libfshelp/translator-list.c
@@ -47,9 +47,12 @@ static pthread_mutex_t translator_ihash_lock = PTHREAD_MUTEX_INITIALIZER;
static void
translator_ihash_cleanup (void *element, void *arg)
{
+ struct translator *translator = element;
+
/* No need to deallocate port, we only keep the name of the
port, not a reference. */
- free (element);
+ free (translator->name);
+ free (translator);
}
/* Record an active translator being bound to the given file name