[Midnightbsd-cvs] src [7915] trunk/usr.sbin/bsdinstall/bsdinstall: Fix "unexpected operator" error when passed multi-word first-argument

laffer1 at midnightbsd.org laffer1 at midnightbsd.org
Wed Sep 14 15:45:51 EDT 2016


Revision: 7915
          http://svnweb.midnightbsd.org/src/?rev=7915
Author:   laffer1
Date:     2016-09-14 15:45:51 -0400 (Wed, 14 Sep 2016)
Log Message:
-----------
Fix "unexpected operator" error when passed multi-word first-argument
containing whitespace. Also make other changes to support multi-word
arguments.

Modified Paths:
--------------
    trunk/usr.sbin/bsdinstall/bsdinstall

Modified: trunk/usr.sbin/bsdinstall/bsdinstall
===================================================================
--- trunk/usr.sbin/bsdinstall/bsdinstall	2016-09-14 19:42:07 UTC (rev 7914)
+++ trunk/usr.sbin/bsdinstall/bsdinstall	2016-09-14 19:45:51 UTC (rev 7915)
@@ -35,11 +35,10 @@
 
 VERB=$1; shift
 
-if [ -z $VERB ]; then
+if [ -z "$VERB" ]; then
 	VERB=auto
 fi
 
 test -d "$BSDINSTALL_TMPETC" || mkdir "$BSDINSTALL_TMPETC"
-echo Running installation step: $VERB $@ >> "$BSDINSTALL_LOG"
-exec /usr/libexec/bsdinstall/$VERB $@ 2>>"$BSDINSTALL_LOG"
-
+echo "Running installation step: $VERB $@" >> "$BSDINSTALL_LOG"
+exec "/usr/libexec/bsdinstall/$VERB" "$@" 2>>"$BSDINSTALL_LOG"



More information about the Midnightbsd-cvs mailing list