summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2019-02-24 07:53:56 -0800
committerKaz Kylheku <kaz@kylheku.com>2019-02-24 07:53:56 -0800
commit8604f52d07c4f58bad2c821f78855fa40bfa9780 (patch)
tree0165ced5990749d0d06f556f1f1618c010a2f861
parent2445c978fc682de3bca5451d230e76cdc1a2ab2d (diff)
downloadtxr-8604f52d07c4f58bad2c821f78855fa40bfa9780.tar.gz
txr-8604f52d07c4f58bad2c821f78855fa40bfa9780.tar.bz2
txr-8604f52d07c4f58bad2c821f78855fa40bfa9780.zip
hash: gc issue in clearhash.
* hash.c (clearhash): Assignment of new table into hash requires setcheck, because it's putting a new object into an old one.
-rw-r--r--hash.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hash.c b/hash.c
index 1667c741..500f1a09 100644
--- a/hash.c
+++ b/hash.c
@@ -876,6 +876,7 @@ val clearhash(val hash)
h->modulus = c_num(mod);
h->count = 0;
h->table = table;
+ setcheck(hash, table);
return oldcount ? num(oldcount) : nil;
}