diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2017-08-13 02:59:00 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2017-08-13 02:59:00 +0200 |
commit | 007ce9f807c99e14799c6579c8d06f422eccfcb2 (patch) | |
tree | e45e06ff46a7737a0553245d4fb397997705aff7 /shell/ash_test | |
parent | 419db0391e47444dd12fb052613fd415694d04f0 (diff) | |
download | busybox-w32-007ce9f807c99e14799c6579c8d06f422eccfcb2.tar.gz busybox-w32-007ce9f807c99e14799c6579c8d06f422eccfcb2.tar.bz2 busybox-w32-007ce9f807c99e14799c6579c8d06f422eccfcb2.zip |
shell: tweak getopts tests, no code changes
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'shell/ash_test')
-rwxr-xr-x | shell/ash_test/ash-getopts/getopt_test_libc_bug.tests | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/shell/ash_test/ash-getopts/getopt_test_libc_bug.tests b/shell/ash_test/ash-getopts/getopt_test_libc_bug.tests index 6c0781f20..fcaac81a2 100755 --- a/shell/ash_test/ash-getopts/getopt_test_libc_bug.tests +++ b/shell/ash_test/ash-getopts/getopt_test_libc_bug.tests | |||
@@ -1,6 +1,6 @@ | |||
1 | # This test can fail with libc with buggy getopt() implementation. | 1 | # This test can fail with libc with buggy getopt() implementation. |
2 | # If getopt() wants to parse multi-option args (-abc), | 2 | # If getopt() wants to parse multi-option args (-abc), |
3 | # it needs to remember a position withit current arg. | 3 | # it needs to remember a position within current arg. |
4 | # | 4 | # |
5 | # If this position is kept as a POINTER, not an offset, | 5 | # If this position is kept as a POINTER, not an offset, |
6 | # and if argv[] ADDRESSES (not contents!) change, it blows up. | 6 | # and if argv[] ADDRESSES (not contents!) change, it blows up. |
@@ -24,7 +24,7 @@ VAR111=NEWVAL; getopts "ac" var -a -b -c -d e; echo "3 rc:$? var:'$var' OPTIND:$ | |||
24 | VAR222=NEWVAL; getopts "ac" var -a -b -c -d e; echo "4 rc:$? var:'$var' OPTIND:$OPTIND OPTARG:'$OPTARG'" | 24 | VAR222=NEWVAL; getopts "ac" var -a -b -c -d e; echo "4 rc:$? var:'$var' OPTIND:$OPTIND OPTARG:'$OPTARG'" |
25 | VAR333=NEWVAL; getopts "ac" var -a -b -c -d e; echo "5 rc:$? var:'$var' OPTIND:$OPTIND OPTARG:'$OPTARG'" | 25 | VAR333=NEWVAL; getopts "ac" var -a -b -c -d e; echo "5 rc:$? var:'$var' OPTIND:$OPTIND OPTARG:'$OPTARG'" |
26 | 26 | ||
27 | # Sligntly different attempts to force reallocations | 27 | # Slightly different attempts to force reallocations |
28 | 28 | ||
29 | echo | 29 | echo |
30 | echo "*** optstring:'ac' args:-a -b -c -d e" | 30 | echo "*** optstring:'ac' args:-a -b -c -d e" |