# New Ticket Created by  [EMAIL PROTECTED] 
# Please include the string:  [perl #18336]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org/rt2/Ticket/Display.html?id=18336 >


System: Solaris 2.8 (SunOS 5.8), UltraSPARC.
Source: CVS snapshot parrot_2002-11-12_000000.tar.gz
Perl: 5.6.1 built with Sun cc.

Did perl Configure.pl and make as in the README.  Ran "./parrot", got
expected options help, and a core dump.  Tried "./parrot -j", typed some
data and ^D and also got a core dump.  Ran dbx on the core, stack trace
showed that it was in mem_sys_free called from PIO_destroy (io/io.c:156
called from Parrot_really_destroy and Parrot_exit).  I noticed that
alloc_pio_array wasn't clearing the allocated array of pointers, and
PIO_destroy is freeing all PIO_NR_OPEN (256) of them every time, and figured
that in tests memory happened to be zeroed so this was never caught.  HTH,
I'd like to get more involved with Parrot.

Dave
Isa. 40:31


-- attachment  1 ------------------------------------------------------
url: http://rt.perl.org/rt2/attach/41470/33354/96560c/parrot-patch-20021111

diff -u io/old_io.c io/io.c
--- io/old_io.c 2002-11-11 22:33:35.311264000 -0600
+++ io/io.c     2002-11-11 22:33:57.654252000 -0600
@@ -64,7 +64,7 @@
 {
     ParrotIOTable newhandles;
     size_t size = numhandles * sizeof(ParrotIO *);
-    newhandles = (ParrotIOTable)mem_sys_allocate(size);
+    newhandles = (ParrotIOTable)mem_sys_allocate_zeroed(size);
     return newhandles;
 }

Reply via email to