diff options
author | Axel Beckert <abe@deuxchevaux.org> | 2018-04-09 00:42:15 +0200 |
---|---|---|
committer | Axel Beckert <abe@deuxchevaux.org> | 2018-04-09 00:42:15 +0200 |
commit | fe36c1ada77f817dbeeeed5ee70c7ba08eeb1d18 (patch) | |
tree | 0229967da5e73bd29a2d6014c847509b361f3631 /Src/Zle/zle_params.c | |
parent | 1521c7d0f7e607b789564e819173e228e9475137 (diff) | |
parent | f9e9dce5443f323b340303596406f9d3ce11d23a (diff) | |
download | zsh-fe36c1ada77f817dbeeeed5ee70c7ba08eeb1d18.tar.gz zsh-fe36c1ada77f817dbeeeed5ee70c7ba08eeb1d18.zip |
Merge tag 'zsh-5.5' and hence branch 'upstream' into branch 'debian'
Release 5.5 of zsh
Diffstat (limited to 'Src/Zle/zle_params.c')
-rw-r--r-- | Src/Zle/zle_params.c | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/Src/Zle/zle_params.c b/Src/Zle/zle_params.c index 0a922d2d6..f3112165a 100644 --- a/Src/Zle/zle_params.c +++ b/Src/Zle/zle_params.c @@ -124,7 +124,7 @@ static const struct gsu_array killring_gsu = static const struct gsu_scalar register_gsu = { strgetfn, set_register, unset_register }; static const struct gsu_hash registers_gsu = -{ hashgetfn, set_registers, zleunsetfn }; +{ hashgetfn, set_registers, unset_registers }; /* implementation is in zle_refresh.c */ static const struct gsu_array region_highlight_gsu = @@ -837,7 +837,17 @@ set_registers(UNUSED(Param pm), HashTable ht) set_register(v.pm, getstrvalue(&v)); } - deleteparamtable(ht); + if (ht != pm->u.hash) + deleteparamtable(ht); +} + +/**/ +static void +unset_registers(Param pm, int exp) +{ + stdunsetfn(pm, exp); + deletehashtable(pm->u.hash); + pm->u.hash = NULL; } static void |