<< Back to previous view

[ASYNC-32] onto-chan retains head of input sequence causing OutOfMemoryError Created: 06/Nov/13  Updated: 06/Nov/13

Status: Open
Project: core.async
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Defect Priority: Major
Reporter: Brian Lubeski Assignee: Rich Hickey
Resolution: Unresolved Votes: 0
Labels: None
Environment:

org.clojure/core.async 0.1.242.0-44b1e3-alpha


Attachments: File patch.clj    
Patch: Code

 Description   

Consider the following example:

(let [c (a/chan)]
(a/onto-chan c (iterate inc 0))
(while true
(a/<!! c)))

onto-chan is holding on to the head of the input sequence as it is unfolded, resulting in an (eventual) OutOfMemoryError.

I've attached a diff showing changes I made to onto-chan that fixed the problem for me.


Generated at Sun Apr 20 21:22:19 CDT 2014 using JIRA 4.4#649-r158309.