diff options
author | Denys Vlasenko | 2017-08-11 02:05:21 +0200 |
---|---|---|
committer | Denys Vlasenko | 2017-08-11 02:05:21 +0200 |
commit | 81f962f3df0d7194b7a52c6f83259727759094c4 (patch) | |
tree | 906d5d55118f0a7c96579c7d12c62b3a14311a7a /shell/hush_test/hush-getopts/getopt_optarg.right | |
parent | 74d40589288890fffea437ed2f38ad1f2dc740e5 (diff) | |
download | busybox-81f962f3df0d7194b7a52c6f83259727759094c4.zip busybox-81f962f3df0d7194b7a52c6f83259727759094c4.tar.gz |
hush: teach getopts to set/unset OPTARG
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell/hush_test/hush-getopts/getopt_optarg.right')
-rw-r--r-- | shell/hush_test/hush-getopts/getopt_optarg.right | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/shell/hush_test/hush-getopts/getopt_optarg.right b/shell/hush_test/hush-getopts/getopt_optarg.right new file mode 100644 index 0000000..9dbd846 --- /dev/null +++ b/shell/hush_test/hush-getopts/getopt_optarg.right @@ -0,0 +1,18 @@ +*** no OPTIND, optstring:'w:et' args:-q -w e -r -t -y +./getopt_optarg.tests: invalid option -- q +var:'?' OPTIND:2 OPTARG:'' +var:'w' OPTIND:4 OPTARG:'e' +./getopt_optarg.tests: invalid option -- r +var:'?' OPTIND:5 OPTARG:'' +var:'t' OPTIND:6 OPTARG:'' +./getopt_optarg.tests: invalid option -- y +var:'?' OPTIND:7 OPTARG:'' +exited: var:'?' OPTIND:7 OPTARG:'' +*** OPTIND=0, optstring:'w:et' args:-w 1 -w2 -w -e -e -t -t +var:'w' OPTIND:3 OPTARG:'1' +var:'w' OPTIND:4 OPTARG:'2' +var:'w' OPTIND:6 OPTARG:'-e' +var:'e' OPTIND:7 OPTARG:'' +var:'t' OPTIND:8 OPTARG:'' +var:'t' OPTIND:9 OPTARG:'' +exited: var:'?' OPTIND:9 OPTARG:'' |