Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Sep 2017 15:50:18 +0000 (UTC)
From:      Peter Holm <pho@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-user@freebsd.org
Subject:   svn commit: r323766 - user/pho/stress2/misc
Message-ID:  <201709191550.v8JFoIYD019781@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: pho
Date: Tue Sep 19 15:50:18 2017
New Revision: 323766
URL: https://svnweb.freebsd.org/changeset/base/323766

Log:
  lidl@ suggested collapsing the 'grep' into the 'awk' invocation.
  Removed a redundant 'rm' from the last commit.
  
  Sponsored by:	Dell EMC Isilon

Modified:
  user/pho/stress2/misc/truncate6.sh

Modified: user/pho/stress2/misc/truncate6.sh
==============================================================================
--- user/pho/stress2/misc/truncate6.sh	Tue Sep 19 15:39:47 2017	(r323765)
+++ user/pho/stress2/misc/truncate6.sh	Tue Sep 19 15:50:18 2017	(r323766)
@@ -57,7 +57,7 @@ rm -f truncate6.c
 cd $mntpoint
 
 /tmp/truncate6
-inode=`ls -ail | grep temp | awk '{print $1}'`
+inode=$(ls -ail | awk '/temp/ {print $1}')
 
 cd $here
 rm -f /tmp/truncate6
@@ -84,7 +84,6 @@ else
 fi
 
 mdconfig -d -u $mdstart
-rm /tmp/truncate6
 exit $e
 EOF
 #include <sys/types.h>



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