From 4d656bfb0ee1ef079bd674187fecca871ceafaab Mon Sep 17 00:00:00 2001 From: Sven Wischnowsky Date: Mon, 26 Jun 2000 08:10:33 +0000 Subject: missing allocation of list for option arguments (12066) --- Src/Zle/computil.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'Src/Zle/computil.c') diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c index a329d34d0..c33a2ef2c 100644 --- a/Src/Zle/computil.c +++ b/Src/Zle/computil.c @@ -1349,6 +1349,8 @@ ca_parse_line(Cadef d, int multi, int first) state.argend = argend; doff = state.doff = 0; state.singles = 1; + if (!state.oargs[state.curopt->num]) + state.oargs[state.curopt->num] = znewlinklist(); goto cont; } else { state.curopt = NULL; @@ -1423,6 +1425,9 @@ ca_parse_line(Cadef d, int multi, int first) if (sopts && nonempty(sopts)) state.curopt = (Caopt) uremnode(sopts, firstnode(sopts)); + if (!state.oargs[state.curopt->num]) + state.oargs[state.curopt->num] = znewlinklist(); + ddef = state.def = state.curopt->args; dopt = state.curopt; doff = pe - line; -- cgit v1.2.3