From 9556424c44d28f6601b867bb0b727db29f36f975 Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Wed, 1 Sep 1999 16:50:09 +0000 Subject: zsh-workers/7616 --- Src/Modules/parameter.c | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'Src/Modules/parameter.c') diff --git a/Src/Modules/parameter.c b/Src/Modules/parameter.c index 10f61c0a5..08c95c610 100644 --- a/Src/Modules/parameter.c +++ b/Src/Modules/parameter.c @@ -617,23 +617,28 @@ boot_parameter(Module m) * As an example for autoloaded parameters, this is probably a bad * example, because we the zsh core doesn't support creation of * special hashes, yet. */ + Param pm; - unsetparam(PAR_NAM); + if ((pm = (Param) gethashnode2(paramtab, PAR_NAM))) + unsetparam_pm(pm, 0, 1); if (!(parpm = createspecialhash(PAR_NAM, getpmparameter, scanpmparameters))) return 1; parpm->flags |= PM_READONLY; - unsetparam(CMD_NAM); + if ((pm = (Param) gethashnode2(paramtab, CMD_NAM))) + unsetparam_pm(pm, 0, 1); if (!(cmdpm = createspecialhash(CMD_NAM, getpmcommand, scanpmcommands))) return 1; cmdpm->sets.hfn = setpmcommands; - unsetparam(FUN_NAM); + if ((pm = (Param) gethashnode2(paramtab, FUN_NAM))) + unsetparam_pm(pm, 0, 1); if (!(funpm = createspecialhash(FUN_NAM, getpmfunction, scanpmfunctions))) return 1; funpm->sets.hfn = setpmfunctions; - unsetparam(OPT_NAM); + if ((pm = (Param) gethashnode2(paramtab, OPT_NAM))) + unsetparam_pm(pm, 0, 1); if (!(optpm = createspecialhash(OPT_NAM, getpmoption, scanpmoptions))) return 1; -- cgit 1.4.1