Variable "table" goes out of scope Reviewed-by: Ander Conselvan de Oliveira <ander.conselvan-de-olive...@nokia.com> Signed-off-by: Erkki Seppälä <erkki.sepp...@vincit.fi> --- src/Xrm.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/src/Xrm.c b/src/Xrm.c index 21f0af3..3e68c37 100644 --- a/src/Xrm.c +++ b/src/Xrm.c @@ -842,8 +842,10 @@ static void PutEntry( nprev = NodeBuckets(table); \ } else { \ table->leaf = 1; \ - if (!(nprev = (NTable *)Xmalloc(sizeof(VEntry *)))) \ + if (!(nprev = (NTable *)Xmalloc(sizeof(VEntry *)))) {\ + Xfree(table); \ return; \ + } \ ((LTable)table)->buckets = (VEntry *)nprev; \ } \ *nprev = (NTable)NULL; \ -- 1.7.0.4 _______________________________________________ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel