From ca0deae382e7798eeff829d9b93472cf876574a3 Mon Sep 17 00:00:00 2001 From: Oliver Kiddle Date: Tue, 20 Apr 2004 12:11:13 +0000 Subject: 19767, 19785: store flags for -z and -k options to autoload allowing the completion system to be used with ksh_autoload set --- Src/builtin.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'Src/builtin.c') diff --git a/Src/builtin.c b/Src/builtin.c index 8703ecead..b7a724cb7 100644 --- a/Src/builtin.c +++ b/Src/builtin.c @@ -2406,9 +2406,16 @@ bin_functions(char *name, char **argv, Options ops, int func) on |= PM_TAGGED; else if (OPT_PLUS(ops,'t')) off |= PM_TAGGED; + if (OPT_MINUS(ops,'z')) + on |= PM_ZSHSTORED; + else if (OPT_PLUS(ops,'z')) + off |= PM_ZSHSTORED; + if (OPT_MINUS(ops,'k')) + on |= PM_KSHSTORED; + else if (OPT_PLUS(ops,'k')) + off |= PM_KSHSTORED; if ((off & PM_UNDEFINED) || (OPT_ISSET(ops,'k') && OPT_ISSET(ops,'z')) || - (!OPT_PLUS(ops,'X') && (OPT_ISSET(ops,'k') || OPT_ISSET(ops,'z'))) || (OPT_MINUS(ops,'X') && (OPT_ISSET(ops,'m') || *argv || !scriptname))) { zwarnnam(name, "invalid option(s)", NULL, 0); return 1; -- cgit 1.4.1