svn commit: r236759 - head/usr.bin/sort

Dimitry Andric dim at FreeBSD.org
Fri Jun 8 17:08:27 UTC 2012


Author: dim
Date: Fri Jun  8 17:08:27 2012
New Revision: 236759
URL: http://svn.freebsd.org/changeset/base/236759

Log:
  In usr.bin/sort, use another method of silencing warnings about unused
  arguments, which does not trigger self-assignment warnings in certain
  circumstances (for example, using clang with ccache).
  
  MFC after:	3 days

Modified:
  head/usr.bin/sort/sort.h

Modified: head/usr.bin/sort/sort.h
==============================================================================
--- head/usr.bin/sort/sort.h	Fri Jun  8 16:16:03 2012	(r236758)
+++ head/usr.bin/sort/sort.h	Fri Jun  8 17:08:27 2012	(r236759)
@@ -41,7 +41,7 @@
 
 #define	VERSION	"2.3-FreeBSD"
 
-#define	UNUSED_ARG(A) do { A=A; } while(0)
+#define	UNUSED_ARG(A) do { (void)(A); } while(0)
 
 #ifdef WITHOUT_NLS
 #define	getstr(n)	 nlsstr[n]


More information about the svn-src-all mailing list