svn commit: r232858 - head/sbin/growfs

Dimitry Andric dim at FreeBSD.org
Mon Mar 12 11:15:44 UTC 2012


Author: dim
Date: Mon Mar 12 11:15:44 2012
New Revision: 232858
URL: http://svn.freebsd.org/changeset/base/232858

Log:
  After r232548, clang complains about the apparent '=-' operator (a
  left-over from ancient C times, and a frequent typo) in growfs.c:
  
  sbin/growfs/growfs.c:1550:8: error: use of unary operator that may be intended as compound assignment (-=) [-Werror]
          blkno =- 1;
                ^~
  
  Use 'blkno = -1' instead, to silence the error.

Modified:
  head/sbin/growfs/growfs.c

Modified: head/sbin/growfs/growfs.c
==============================================================================
--- head/sbin/growfs/growfs.c	Mon Mar 12 11:04:48 2012	(r232857)
+++ head/sbin/growfs/growfs.c	Mon Mar 12 11:15:44 2012	(r232858)
@@ -1547,7 +1547,7 @@ alloc(void)
 	 * block here which we have to relocate a couple of seconds later again
 	 * again, and we are not prepared to to this anyway.
 	 */
-	blkno =- 1;
+	blkno = -1;
 	dlower = cgsblock(&sblock, acg.cg_cgx) - cgbase(&sblock, acg.cg_cgx);
 	dupper = cgdmin(&sblock, acg.cg_cgx) - cgbase(&sblock, acg.cg_cgx);
 	dmax = cgbase(&sblock, acg.cg_cgx) + sblock.fs_fpg;


More information about the svn-src-all mailing list