[Pkg-shadow-commits] r2017 - in upstream/trunk: . libmisc

nekral-guest at alioth.debian.org nekral-guest at alioth.debian.org
Sun May 25 20:39:33 UTC 2008


Author: nekral-guest
Date: 2008-05-25 20:39:31 +0000 (Sun, 25 May 2008)
New Revision: 2017

Modified:
   upstream/trunk/ChangeLog
   upstream/trunk/libmisc/xmalloc.c
Log:
Avoid implicit conversion of integers / pointers to booleans.


Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog	2008-05-25 20:37:51 UTC (rev 2016)
+++ upstream/trunk/ChangeLog	2008-05-25 20:39:31 UTC (rev 2017)
@@ -1,5 +1,10 @@
 2008-05-25  Nicolas François  <nicolas.francois at centraliens.net>
 
+	* libmisc/xmalloc.c: Avoid implicit conversion of integers /
+	pointers to booleans.
+
+2008-05-25  Nicolas François  <nicolas.francois at centraliens.net>
+
 	* configure.in, lib/defines.h: Allow usage of booleans in the
 	source.
 

Modified: upstream/trunk/libmisc/xmalloc.c
===================================================================
--- upstream/trunk/libmisc/xmalloc.c	2008-05-25 20:37:51 UTC (rev 2016)
+++ upstream/trunk/libmisc/xmalloc.c	2008-05-25 20:39:31 UTC (rev 2017)
@@ -52,7 +52,7 @@
 	char *ptr;
 
 	ptr = (char *) malloc (size);
-	if (!ptr && size) {
+	if ((NULL == ptr) && (0 != size)) {
 		fprintf (stderr, _("malloc(%d) failed\n"), (int) size);
 		exit (13);
 	}




More information about the Pkg-shadow-commits mailing list