prop->name is allocated in code but check is for parameter name that
can't be NULL.

Signed-off-by: Pauli Nieminen <ext-pauli.niemi...@nokia.com>
---
 xkb/XKBGAlloc.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/xkb/XKBGAlloc.c b/xkb/XKBGAlloc.c
index d1adea3..7143e7a 100644
--- a/xkb/XKBGAlloc.c
+++ b/xkb/XKBGAlloc.c
@@ -669,7 +669,7 @@ register XkbPropertyPtr prop;
     }
     prop= &geom->properties[geom->num_properties];
     prop->name= malloc(strlen(name)+1);
-    if (!name)
+    if (!prop->name)
        return NULL;
     strcpy(prop->name,name);
     prop->value= malloc(strlen(value)+1);
-- 
1.6.3.3

_______________________________________________
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

Reply via email to