From 184ef0d35612d6ed0619283d376f04d9a904f47c Mon Sep 17 00:00:00 2001 From: Pauli Nieminen Date: Thu, 22 Jul 2010 11:34:54 +0300 Subject: xkb: Don't check for NULL before calling free Signed-off-by: Pauli Nieminen Reviewed-by: Peter Hutterer --- xkb/ddxList.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'xkb') diff --git a/xkb/ddxList.c b/xkb/ddxList.c index 39bd7397a..c1ada5c6d 100644 --- a/xkb/ddxList.c +++ b/xkb/ddxList.c @@ -202,8 +202,7 @@ char tmpname[PATH_MAX]; } if (!in) { - if (buf != NULL) - free(buf); + free(buf); #ifdef WIN32 unlink(tmpname); #endif @@ -266,8 +265,7 @@ char tmpname[PATH_MAX]; fclose(in); unlink(tmpname); #endif - if (buf != NULL) - free(buf); + free(buf); return status; } -- cgit v1.2.3