[MacRuby] #1301: Dispatch::Source.timer leaks memory

MacRuby ruby-noreply at macosforge.org
Mon May 23 18:08:24 PDT 2011


#1301: Dispatch::Source.timer leaks memory
-----------------------------------+----------------------------------------
 Reporter:  lsansonetti@…          |       Owner:  lsansonetti@…        
     Type:  defect                 |      Status:  new                  
 Priority:  blocker                |   Milestone:                       
Component:  MacRuby                |    Keywords:                       
-----------------------------------+----------------------------------------
 Probably because in rb_source_init() we retain ourselves...

 Removing the GC_RETAIN() call fixes the fact that Source objects were
 never finalized, but it  causes a segfault in the following reduction:

 {{{
 ./miniruby -e "q=Dispatch::Queue.new('local'); loop { 10.times {
 Dispatch::Source.timer(0, 0, 0, q) {} }; GC.start }"
 }}}

-- 
Ticket URL: <http://www.macruby.org/trac/ticket/1301>
MacRuby <http://macruby.org/>



More information about the macruby-tickets mailing list