Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 25 Oct 2014 05:31:19 +0000 (UTC)
From:      Garrett Cooper <ngie@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r273628 - head/tools/regression/zfs
Message-ID:  <201410250531.s9P5VJxu087163@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: ngie
Date: Sat Oct 25 05:31:18 2014
New Revision: 273628
URL: https://svnweb.freebsd.org/changeset/base/273628

Log:
  Move the redirection to stderr out of the cmd variable assignment
  
  Putting 2>/dev/null in cmd= escapes the redirection operation, which causes
  mdconfig to think it's a filename
  
  MFC after: 2 weeks
  X-MFC with: r273627
  Sponsored by: EMC / Isilon Storage Division

Modified:
  head/tools/regression/zfs/misc.sh

Modified: head/tools/regression/zfs/misc.sh
==============================================================================
--- head/tools/regression/zfs/misc.sh	Sat Oct 25 04:52:48 2014	(r273627)
+++ head/tools/regression/zfs/misc.sh	Sat Oct 25 05:31:18 2014	(r273628)
@@ -167,8 +167,8 @@ create_memdisk()
 		if [ -n "${devname}" ]; then
 			devparam="-u ${devname}"
 		fi
-		cmd="mdconfig -a -t swap -s ${size} ${devparam} 2>/dev/null"
-		DISKNAME=`${cmd}` || die "failed: ${cmd}"
+		cmd="mdconfig -a -t swap -s ${size} ${devparam}"
+		DISKNAME=`$cmd 2>/dev/null` || die "failed: ${cmd}"
 		if [ -n "${devname}" ]; then
 			DISKNAME="${devname}"
 		fi



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