svn commit: r270989 - head/usr.sbin/bsdconfig/share
Devin Teske
dteske at FreeBSD.org
Tue Sep 2 22:59:41 UTC 2014
Author: dteske
Date: Tue Sep 2 22:59:40 2014
New Revision: 270989
URL: http://svnweb.freebsd.org/changeset/base/270989
Log:
Fix regression introduced by SVN r270954. Correct way to reset getopts
is to set OPTIND to 1, not unset it (which causes an error).
Thanks to: jilles
Modified:
head/usr.sbin/bsdconfig/share/dialog.subr
Modified: head/usr.sbin/bsdconfig/share/dialog.subr
==============================================================================
--- head/usr.sbin/bsdconfig/share/dialog.subr Tue Sep 2 22:01:14 2014 (r270988)
+++ head/usr.sbin/bsdconfig/share/dialog.subr Tue Sep 2 22:59:40 2014 (r270989)
@@ -2116,7 +2116,7 @@ f_dialog_init()
f_dprintf "f_dialog_init: ARGV=[%s] GETOPTS_STDARGS=[%s]" \
"$ARGV" "$GETOPTS_STDARGS"
SECURE=`set -- $ARGV
- unset OPTIND
+ OPTIND=1
while getopts \
"$GETOPTS_STDARGS$GETOPTS_EXTRA$GETOPTS_ALLFLAGS" \
flag > /dev/null; do
@@ -2126,7 +2126,7 @@ f_dialog_init()
done
` # END-BACKTICK
USE_XDIALOG=`set -- $ARGV
- unset OPTIND
+ OPTIND=1
while getopts \
"$GETOPTS_STDARGS$GETOPTS_EXTRA$GETOPTS_ALLFLAGS" \
flag > /dev/null; do
More information about the svn-src-head
mailing list