summary refs log tree commit diff
path: root/intl/dcigettext.c
diff options
context:
space:
mode:
Diffstat (limited to 'intl/dcigettext.c')
-rw-r--r--intl/dcigettext.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/intl/dcigettext.c b/intl/dcigettext.c
index 23e019ab32..ad2835f930 100644
--- a/intl/dcigettext.c
+++ b/intl/dcigettext.c
@@ -949,7 +949,10 @@ _nl_find_msg (domain_file, domainbinding, msgid, convert, lengthp)
 			   nothing to do.  Otherwise do not use the
 			   translation at all.  */
 			if (__builtin_expect (r != __GCONV_NULCONV, 1))
-			  return NULL;
+			  {
+			    free ((char *) encoding);
+			    return NULL;
+			  }
 
 			convd->conv = (__gconv_t) -1;
 		      }