projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
e440b39
)
awk: stop on first non-option, closes 9861
author
Denys Vlasenko
<vda.linux@googlemail.com>
Wed, 16 Aug 2017 17:07:53 +0000
(19:07 +0200)
committer
Denys Vlasenko
<vda.linux@googlemail.com>
Wed, 16 Aug 2017 17:07:53 +0000
(19:07 +0200)
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
editors/awk.c
patch
|
blob
|
history
diff --git
a/editors/awk.c
b/editors/awk.c
index 372a255bdc0a6816ee293c546f842195b2120431..2005329ad6a7329e9c2027cf68ce8d21aaafad84 100644
(file)
--- a/
editors/awk.c
+++ b/
editors/awk.c
@@
-70,7
+70,11
@@
#endif
#endif
-#define OPTSTR_AWK \
+/* "+": stop on first non-option:
+ * $ awk 'BEGIN { for(i=1; i<ARGC; ++i) { print i ": " ARGV[i] }}' -argz
+ * 1: -argz
+ */
+#define OPTSTR_AWK "+" \
"F:v:*f:*" \
IF_FEATURE_AWK_GNU_EXTENSIONS("e:*") \
"W:"
"F:v:*f:*" \
IF_FEATURE_AWK_GNU_EXTENSIONS("e:*") \
"W:"