about summary refs log tree commit diff
path: root/Src/Modules
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-05 07:57:27 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-05 07:57:27 +0000
commitf94e5d78b06d2641e08d61f48c100eb205f5ac0a (patch)
tree8ee6afc85258918b0efe63d7482039e1a27d146f /Src/Modules
parentd1813a007f2343402d1de883403278f91da1ab53 (diff)
downloadzsh-f94e5d78b06d2641e08d61f48c100eb205f5ac0a.tar.gz
zsh-f94e5d78b06d2641e08d61f48c100eb205f5ac0a.tar.xz
zsh-f94e5d78b06d2641e08d61f48c100eb205f5ac0a.zip
some more memory leak fixes (11745)
Diffstat (limited to 'Src/Modules')
-rw-r--r--Src/Modules/parameter.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/Src/Modules/parameter.c b/Src/Modules/parameter.c
index bdced0680..d7c3ba690 100644
--- a/Src/Modules/parameter.c
+++ b/Src/Modules/parameter.c
@@ -192,9 +192,10 @@ scanpmparameters(HashTable ht, ScanFunc func, int flags)
 static void
 setpmcommand(Param pm, char *value)
 {
-    if (isset(RESTRICTED))
+    if (isset(RESTRICTED)) {
 	zwarn("restricted: %s", value, 0);
-    else {
+	zsfree(value);
+    } else {
 	Cmdnam cn = zcalloc(sizeof(*cn));
 
 	cn->flags = HASHED;