summaryrefslogtreecommitdiffstats
path: root/bin/sh/eval.c
diff options
context:
space:
mode:
Diffstat (limited to 'bin/sh/eval.c')
-rw-r--r--bin/sh/eval.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/bin/sh/eval.c b/bin/sh/eval.c
index a47d045..e2f66ed 100644
--- a/bin/sh/eval.c
+++ b/bin/sh/eval.c
@@ -1170,6 +1170,12 @@ truecmd(int argc __unused, char **argv __unused)
int
execcmd(int argc, char **argv)
{
+ /*
+ * Because we have historically not supported any options,
+ * only treat "--" specially.
+ */
+ if (argc > 1 && strcmp(argv[1], "--") == 0)
+ argc--, argv++;
if (argc > 1) {
struct strlist *sp;
OpenPOWER on IntegriCloud