Date: Sun, 21 Jun 2009 07:54:48 +0000 (UTC) From: Roman Divacky <rdivacky@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r194575 - head/sys/kern Message-ID: <200906210754.n5L7smrr099523@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rdivacky Date: Sun Jun 21 07:54:47 2009 New Revision: 194575 URL: http://svn.freebsd.org/changeset/base/194575 Log: In non-debugging mode make this define (void)0 instead of nothing. This helps to catch bugs like the below with clang. if (cond); <--- note the trailing ; something(); Approved by: ed (mentor) Discussed on: current@ Modified: head/sys/kern/sysv_msg.c Modified: head/sys/kern/sysv_msg.c ============================================================================== --- head/sys/kern/sysv_msg.c Sun Jun 21 07:34:12 2009 (r194574) +++ head/sys/kern/sysv_msg.c Sun Jun 21 07:54:47 2009 (r194575) @@ -80,7 +80,7 @@ static int sysvmsg_modload(struct module #ifdef MSG_DEBUG #define DPRINTF(a) printf a #else -#define DPRINTF(a) +#define DPRINTF(a) (void)0 #endif static void msg_freehdr(struct msg *msghdr);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200906210754.n5L7smrr099523>