Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 12 Mar 2016 18:55:48 +0000 (UTC)
From:      Garrett Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org
Subject:   svn commit: r296742 - stable/10/sbin/swapon
Message-ID:  <201603121855.u2CItmrB070123@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Sat Mar 12 18:55:48 2016
New Revision: 296742
URL: https://svnweb.freebsd.org/changeset/base/296742

Log:
  MFC r295121:
  
  Delete argsize to fix a -Wunused-but-set-variable warning with gcc 4.9
  
  The variable isn't actually checked -- just the end result which gets
  returned from the function

Modified:
  stable/10/sbin/swapon/swapon.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sbin/swapon/swapon.c
==============================================================================
--- stable/10/sbin/swapon/swapon.c	Sat Mar 12 18:55:16 2016	(r296741)
+++ stable/10/sbin/swapon/swapon.c	Sat Mar 12 18:55:48 2016	(r296742)
@@ -315,7 +315,7 @@ swap_on_geli_args(const char *mntops)
 	const char *aalgo, *ealgo, *keylen_str, *sectorsize_str;
 	const char *aflag, *eflag, *lflag, *sflag;
 	char *p, *args, *token, *string, *ops;
-	int argsize, pagesize;
+	int pagesize;
 	size_t pagesize_len;
 	u_long ul;
 
@@ -387,7 +387,7 @@ swap_on_geli_args(const char *mntops)
 		sectorsize_str = p;
 	}
 
-	argsize = asprintf(&args, "%s%s%s%s%s%s%s%s -d",
+	(void)asprintf(&args, "%s%s%s%s%s%s%s%s -d",
 	    aflag, aalgo, eflag, ealgo, lflag, keylen_str,
 	    sflag, sectorsize_str);
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201603121855.u2CItmrB070123>