chicken-janitors
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Chicken-janitors] #723: using set-finalizer in this loop triggers a OOM


From: Chicken Trac
Subject: [Chicken-janitors] #723: using set-finalizer in this loop triggers a OOM panic / segfault
Date: Sat, 05 Nov 2011 13:14:34 -0000

#723: using set-finalizer in this loop triggers a OOM panic / segfault
---------------------+------------------------------------------------------
 Reporter:  ckeen    |       Owner:  felix
     Type:  defect   |      Status:  new  
 Priority:  major    |   Milestone:  4.8.0
Component:  unknown  |     Version:  4.7.x
 Keywords:           |  
---------------------+------------------------------------------------------
 This innocent looking program crashes:

 {{{
 (use lolevel)

 (define (make-stuff)
   (let ((mem (allocate 100)))
     (set-finalizer! mem free)
     mem))

 (let lp ((i 0))
   (make-stuff)
   (lp (add1 i)))
 }}}

 This has been confirmed by Peter on NetBSD, I have the situation that it
 works for me if I add a (print i) before (make-stuff). Peter cannot see
 the same behaviour on his machine.

 I have tried 4.5.0 4.7.0 and master from last week. All show the same
 strange thing.

 Am I misusing this?  I stumbled upon it during some allocation in an egg
 for a FFI buffer...

-- 
Ticket URL: <http://bugs.call-cc.org/ticket/723>
Chicken Scheme <http://www.call-with-current-continuation.org/>
Chicken Scheme is a compiler for the Scheme programming language.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]