diff options
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | stream.c | 8 |
2 files changed, 15 insertions, 1 deletions
@@ -1,3 +1,11 @@ +2014-03-02 Kaz Kylheku <kaz@kylheku.com> + + Bugfix: catenated stream objects not hooked into garbage collector, + causing premature collection of the catenated stream list. + + * stream.c (cat_mark): new function. + (cat_stream_ops): use cat_mark for gc mark function. + 2014-03-01 Kaz Kylheku <kaz@kylheku.com> New quasiquote idea: let's have two quasiquote macros sharing one @@ -2336,11 +2336,17 @@ static val cat_get_prop(val stream, val ind) return nil; } +static void cat_mark(val stream) +{ + val obj = (val) stream->co.handle; + gc_mark(obj); +} + static struct strm_ops cat_stream_ops = { { eq, cat_stream_print, cobj_destroy_stub_op, - cobj_mark_op, + cat_mark, cobj_hash_op }, 0, /* put_string */ 0, /*_put_char */ |