docs/154289: Typing error in demo script inside man page "getopt(1)"
Jamie Landeg Jones
jamie at bishopston.net
Tue Jan 25 18:10:12 UTC 2011
>Number: 154289
>Category: docs
>Synopsis: Typing error in demo script inside man page "getopt(1)"
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-doc
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: doc-bug
>Submitter-Id: current-users
>Arrival-Date: Tue Jan 25 18:10:11 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator: Jamie Landeg Jones
>Release: FreeBSD 8.2-PRERELEASE i386
>Organization:
http://www.bishopston.com/jamie/
>Environment:
System: FreeBSD catflap.bishopston.net 8.2-PRERELEASE FreeBSD 8.2-PRERELEASE #0: Wed Jan 19 12:51:26 GMT 2011 root at catflap.bishopston.net:/usr/obj/usr/src/sys/CATFLAP i386
>Description:
getopt(1) man page contains the following within the sample code:
-a|-b)
echo flag $i set; sflags="${i#-}$sflags";
shift;;
-o)
$i and ${i are wrong - they should be $1 and ${1 respectively - as it stands, the example doesn't show which flag is being set
>How-To-Repeat:
man getopt
>Fix:
replace $i with $1 and ${i with ${1
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-doc
mailing list