summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorFelix Dietrich <felix.dietrich@sperrhaken.name>2015-06-02 22:55:19 +0200
committerHerbert Xu <herbert@gondor.apana.org.au>2015-06-11 14:31:48 +0800
commitd7582e69da222e48002ef79ec1d97d55fc469dd6 (patch)
tree4db228a827c8c8037d73fcfc5a13dd7a6b72d30c /src
parentbuiltin: Clear LC_ALL in mkbuiltins (diff)
downloaddash-d7582e69da222e48002ef79ec1d97d55fc469dd6.tar.gz
dash-d7582e69da222e48002ef79ec1d97d55fc469dd6.zip
man: Fix description of getopts when last argument reached
The description of getops in the manual incorrectly states that
var will be set to "--" when no arguments remain.  In fact it
will be set to "?".

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to '')
-rw-r--r--src/dash.19
1 files changed, 2 insertions, 7 deletions
diff --git a/src/dash.1 b/src/dash.1
index 693c970..832eae7 100644
--- a/src/dash.1
+++ b/src/dash.1
@@ -1402,14 +1402,9 @@ By specifying a colon as the first character of
 .Va optstring
 all errors will be ignored.
 .Pp
-A nonzero value is returned when the last option is reached.
-If there are no remaining arguments,
+After the last option
 .Ic getopts
-will set
-.Va var
-to the special option,
-.Dq -- ,
-otherwise, it will set
+will return a non-zero value and set
 .Va var
 to
 .Dq \&? .
f8dd666a4e379c282e388b&follow=1'>Add /help equivalent to /manJune McEnroe 2018-09-11Don't render every PM as a pingJune McEnroe 2018-09-11Add urlOpenMatchJune McEnroe 2018-09-10Depend on man.sh for chroot.tar targetJune McEnroe 2018-09-10Set LESSSECURE=1 in man.shJune McEnroe 2018-09-10Add /man commandJune McEnroe 2018-09-10Install man page in chrootJune McEnroe 2018-09-10Install man pageJune McEnroe 2018-09-10Split keys into subsections and document colorsJune McEnroe 2018-09-10Add "blank" lines to chatte.1June McEnroe 2018-09-10Document key bindings in chatte.1June McEnroe 2018-09-08Document slash commands in chatte.1June McEnroe