about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2004-01-15 11:10:46 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2004-01-15 11:10:46 +0000
commit915e17ee4bb62b82c153d45c1e0eff36bbcdea82 (patch)
treef8fb68bb1891a945322e0a15df428086ad580b8b
parent88af97c80e38cde6483145ff767aacda7d519fab (diff)
downloadzsh-915e17ee4bb62b82c153d45c1e0eff36bbcdea82.tar.gz
zsh-915e17ee4bb62b82c153d45c1e0eff36bbcdea82.tar.xz
zsh-915e17ee4bb62b82c153d45c1e0eff36bbcdea82.zip
19374: fix typo in 19361
-rw-r--r--ChangeLog5
-rw-r--r--Src/params.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index ff197dfdc..d2686e186 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2004-01-15  Peter Stephenson  <pws@csr.com>
+
+	* 19374: Src/params.c: typo in 19361 caused crashes when
+	unsetting special parameters tied internally to arrays.
+
 2004-01-14  Peter Stephenson  <pws@csr.com>
 
 	* 19364: Completion/Unix/Command/.distfiles,
diff --git a/Src/params.c b/Src/params.c
index 90389c40c..5a5283df9 100644
--- a/Src/params.c
+++ b/Src/params.c
@@ -2585,7 +2585,7 @@ arrvarsetfn(Param pm, char **x)
      * ways which need to be set to NULL.  We can't do this
      * with user tied variables since we can leak memory.
      */
-    if ((pm->flags & PM_SPECIAL) & !x)
+    if ((pm->flags & PM_SPECIAL) && !x)
 	*dptr = mkarray(NULL);
     else
 	*dptr = x;