summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKaz Kylheku <kaz@kylheku.com>2021-04-28 06:54:43 -0700
committerKaz Kylheku <kaz@kylheku.com>2021-04-28 06:54:43 -0700
commit9aeea739dd31595f150881f6a525cbda3a2ee44d (patch)
tree77cfc555a90f2a4b576554a3e2373eaea9471e97
parentbfd36f581181df38c86394bad1c48f6fa19451db (diff)
downloadtxr-9aeea739dd31595f150881f6a525cbda3a2ee44d.tar.gz
txr-9aeea739dd31595f150881f6a525cbda3a2ee44d.tar.bz2
txr-9aeea739dd31595f150881f6a525cbda3a2ee44d.zip
seq-iter: gc issue.
* lib.c (seq_iter_mark): The default case checks the type of the wrong object. The seq_iter object is necessarily a cobjp, and necessarily not a obj_struct_p so the test is always false, and we do not call gc_mark(si->ui.iter). The check must be applied to the object being iterated.
-rw-r--r--lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib.c b/lib.c
index 2f0f9859..82869026 100644
--- a/lib.c
+++ b/lib.c
@@ -903,7 +903,7 @@ static void seq_iter_mark(val seq_iter)
gc_mark(si->ui.iter);
break;
default:
- if (cobjp(seq_iter) && obj_struct_p(seq_iter))
+ if (cobjp(si->inf.obj) && obj_struct_p(si->inf.obj))
gc_mark(si->ui.iter);
break;
}