diff options
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | Src/Zle/computil.c | 3 |
2 files changed, 7 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog index 0f8402780..d6c82887e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -5,6 +5,11 @@ * unposted: Completion/Unix/Command/_ruby: fix typo in first normal arg action +2005-07-11 Bart Schaefer <schaefer@zsh.org> + + * 21428: Travis Spencer: Src/Zle/computil.c: fix null pointer deref + on wrong number of arguments to compvalues. + 2005-07-10 Bart Schaefer <schaefer@zsh.org> * 21423: Travis Spencer: Completion/Unix/Command/_unexpand: diff --git a/Src/Zle/computil.c b/Src/Zle/computil.c index aa62cc78b..e56972cee 100644 --- a/Src/Zle/computil.c +++ b/Src/Zle/computil.c @@ -2660,7 +2660,8 @@ parse_cvdef(char *nam, char **args) char **oargs = args, sep = '\0', asep = '=', *name, *descr, *p, *q, **xor, c; int xnum, multi, vtype, hassep = 0, words = 0; - while (args[0][0] == '-' && + while (args && args[0] && args[1] && + args[0][0] == '-' && (args[0][1] == 's' || args[0][1] == 'S' || args[0][1] == 'w') && !args[0][2]) { |