Coverity #905: Handle_Prop_Requests returned without freeing storage "thunks"
authorAlan Coopersmith <alan.coopersmith@sun.com>
Fri, 10 Aug 2007 19:08:57 +0000 (12:08 -0700)
committerAlan Coopersmith <alan.coopersmith@sun.com>
Fri, 10 Aug 2007 19:08:57 +0000 (12:08 -0700)
xprop.c

diff --git a/xprop.c b/xprop.c
index 2279219..c026c11 100644 (file)
--- a/xprop.c
+++ b/xprop.c
@@ -1287,14 +1287,14 @@ Handle_Prop_Requests (int argc, char **argv)
     char *format, *dformat, *prop;
     thunk *thunks, t;
 
-    thunks = Create_Thunk_List();
-
     /* if no prop referenced, by default list all properties for given window */
     if (!argc) {
        Show_All_Props();
        return NULL;
     }
 
+    thunks = Create_Thunk_List();
+
     while (argc > 0) {
        format = NULL;
        dformat = NULL;