aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/lib
diff options
context:
space:
mode:
authorErkki Seppälä <erkki.seppala@vincit.fi>2011-01-31 14:01:59 +0200
committerUlrich Sibiller <uli42@gmx.de>2016-10-19 21:40:26 +0200
commit79cb50e4c4e88921b7f97da5431641cc842c19f7 (patch)
treee3e66a2b0286303d8d3b0517a218e0cdba9aa43f /nx-X11/lib
parent44e472068b163b7be001b74fec1ed98bcdde85e2 (diff)
downloadnx-libs-79cb50e4c4e88921b7f97da5431641cc842c19f7.tar.gz
nx-libs-79cb50e4c4e88921b7f97da5431641cc842c19f7.tar.bz2
nx-libs-79cb50e4c4e88921b7f97da5431641cc842c19f7.zip
ximcp/imRmAttr: Handle leaking missing_list
Fixed memory leak by adding Xfree and initializing missing_list with NULL Variable "missing_list" goes out of scope Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Ander Conselvan de Oliveira <ander.conselvan-de-oliveira@nokia.com> Signed-off-by: Erkki Seppälä <erkki.seppala@vincit.fi> Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Backported-to-NX-by: Ulrich Sibiller <uli42@gmx.de>
Diffstat (limited to 'nx-X11/lib')
-rw-r--r--nx-X11/lib/X11/imRmAttr.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/nx-X11/lib/X11/imRmAttr.c b/nx-X11/lib/X11/imRmAttr.c
index 09521653d..fcb347caa 100644
--- a/nx-X11/lib/X11/imRmAttr.c
+++ b/nx-X11/lib/X11/imRmAttr.c
@@ -316,7 +316,7 @@ _XimAttributeToValue(
INT16 len = data[0];
char *base_name;
XFontSet rep = (XFontSet)NULL;
- char **missing_list;
+ char **missing_list = NULL;
int missing_count;
char *def_string;
@@ -350,6 +350,7 @@ _XimAttributeToValue(
}
Xfree(base_name);
+ Xfree(missing_list);
*((XFontSet *)value) = rep;
break;
}