diff options
author | Oliver Kiddle <opk@users.sourceforge.net> | 2001-12-17 11:10:46 +0000 |
---|---|---|
committer | Oliver Kiddle <opk@users.sourceforge.net> | 2001-12-17 11:10:46 +0000 |
commit | 13ab7280aa553e2398b8aab8a9e66d32f43599ce (patch) | |
tree | 5892fddab738135aff572eaf5e46d6b16156be6a | |
parent | 3902c8ea8d515b36725f5d97b4df45232632c754 (diff) | |
download | zsh-13ab7280aa553e2398b8aab8a9e66d32f43599ce.tar.gz zsh-13ab7280aa553e2398b8aab8a9e66d32f43599ce.tar.xz zsh-13ab7280aa553e2398b8aab8a9e66d32f43599ce.zip |
fix bug in parameter unset code that caused seg fault (16351)
-rw-r--r-- | ChangeLog | 10 | ||||
-rw-r--r-- | Src/params.c | 3 |
2 files changed, 9 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog index 5acb0072f..dc8887f29 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,10 +1,14 @@ +2001-12-17 Oliver Kiddle <opk@zsh.org> + + * 16351: Src/params.c: fix bug in parameter unset code + 2001-12-17 Clint Adams <clint@zsh.org> - * Completion/Debian/Command/.distfiles, - * Completion/Debian/Command/_make-kpkg: completion for + * 16349: Completion/Debian/Command/.distfiles, + Completion/Debian/Command/_make-kpkg: completion for make-kpkg. - * ref 16347: Src/params.c, Src/subst.c: + * 16347: Src/params.c, Src/subst.c: tweaks pointed out by Zefram. 2001-12-16 Clint Adams <clint@zsh.org> diff --git a/Src/params.c b/Src/params.c index ac7f084bd..5c4d61e69 100644 --- a/Src/params.c +++ b/Src/params.c @@ -2174,7 +2174,8 @@ stdunsetfn(Param pm, int exp) switch (PM_TYPE(pm->flags)) { case PM_SCALAR: pm->sets.cfn(pm, NULL); break; case PM_ARRAY: pm->sets.afn(pm, NULL); break; - case PM_HASHED: pm->sets.hfn(pm, NULL); break; + case PM_HASHED: pm->sets.hfn(pm, NULL); break; + default: pm->u.str = NULL; break; } pm->flags |= PM_UNSET; } |