diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2017-08-16 19:07:53 +0200 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2017-08-16 19:07:53 +0200 |
commit | a1799db4ac660a15285e1ac2464b5f622746d787 (patch) | |
tree | 3cdbba58ebc8d20aa20c3dcb571498c1386b2dd9 | |
parent | e440b39416e7876129e619f7aa6935c783020645 (diff) | |
download | busybox-w32-a1799db4ac660a15285e1ac2464b5f622746d787.tar.gz busybox-w32-a1799db4ac660a15285e1ac2464b5f622746d787.tar.bz2 busybox-w32-a1799db4ac660a15285e1ac2464b5f622746d787.zip |
awk: stop on first non-option, closes 9861
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
-rw-r--r-- | editors/awk.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/editors/awk.c b/editors/awk.c index 372a255bd..2005329ad 100644 --- a/editors/awk.c +++ b/editors/awk.c | |||
@@ -70,7 +70,11 @@ | |||
70 | #endif | 70 | #endif |
71 | 71 | ||
72 | 72 | ||
73 | #define OPTSTR_AWK \ | 73 | /* "+": stop on first non-option: |
74 | * $ awk 'BEGIN { for(i=1; i<ARGC; ++i) { print i ": " ARGV[i] }}' -argz | ||
75 | * 1: -argz | ||
76 | */ | ||
77 | #define OPTSTR_AWK "+" \ | ||
74 | "F:v:*f:*" \ | 78 | "F:v:*f:*" \ |
75 | IF_FEATURE_AWK_GNU_EXTENSIONS("e:*") \ | 79 | IF_FEATURE_AWK_GNU_EXTENSIONS("e:*") \ |
76 | "W:" | 80 | "W:" |