No subject


Fri Oct 29 08:20:29 PDT 2010


XtFree() can handle NULL , remove check

Signed-off-by: walter harms <wharms at bfs.de>
---
 src/Varargs.c |    5 ++---
 1 files changed, 2 insertions(+), 3 deletions(-)

diff --git a/src/Varargs.c b/src/Varargs.c
index b03c889..6c9f9ee 100644
--- a/src/Varargs.c
+++ b/src/Varargs.c
@@ -318,7 +318,7 @@ _XtFreeArgList(
     if (args) {
 	if (typed_count)
 	    for (p = args + total_count; total_count--; ++p) {
-		if (p->value) XtFree((char *)p->value);
+		XtFree((char *)p->value);
 	    }
 	XtFree((char *)args);
     }
@@ -398,8 +398,7 @@ _XtVaToArgList(
 	}
     }

-    if (resources != NULL)
-	XtFree((XtPointer)resources);
+    XtFree((XtPointer)resources);

     *num_args_return = (Cardinal)count;
     *args_return = (ArgList)args;
-- 
1.6.0.2



More information about the xorg-devel mailing list