Author: emaste
Date: Tue Nov  1 14:50:32 2016
New Revision: 308171
URL: https://svnweb.freebsd.org/changeset/base/308171

Log:
  arm64 make-memstick.sh: use 'set -e' to abort if any step fails
  
  Also remove the now-redundant error handling that was only for makefs.
  
  This script was run on an older FreeBSD host that lacked efi-on-mbr
  support in makefs. A warning was emitted on the console (from makefs)
  but the script continued running and exited with 0.
  
  Reviewed by:  gjb
  Sponsored by: The FreeBSD Foundation

Modified:
  head/release/arm64/make-memstick.sh

Modified: head/release/arm64/make-memstick.sh
==============================================================================
--- head/release/arm64/make-memstick.sh Tue Nov  1 13:54:44 2016        
(r308170)
+++ head/release/arm64/make-memstick.sh Tue Nov  1 14:50:32 2016        
(r308171)
@@ -10,6 +10,8 @@
 # $FreeBSD$
 #
 
+set -e
+
 PATH=/bin:/usr/bin:/sbin:/usr/sbin
 export PATH
 
@@ -31,10 +33,6 @@ fi
 echo '/dev/ufs/FreeBSD_Install / ufs ro,noatime 1 1' > ${1}/etc/fstab
 echo 'root_rw_mount="NO"' > ${1}/etc/rc.conf.local
 makefs -B little -o label=FreeBSD_Install ${2}.part ${1}
-if [ $? -ne 0 ]; then
-       echo "makefs failed"
-       exit 1
-fi
 rm ${1}/etc/fstab
 rm ${1}/etc/rc.conf.local
 
_______________________________________________
[email protected] mailing list
https://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"

Reply via email to