# \[BUG\] run with -rprofile -rtest/unit

**URL:** <https://www.ruby-forum.com/t/bug-run-with-rprofile-rtest-unit/60267>\
**Category:** Development\
**Created:** [May 11, 2006, 7:16pm UTC](https://www.ruby-forum.com/t/bug-run-with-rprofile-rtest-unit/60267 "2006-05-11T19:16:06Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Takaaki\_T](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/dc4da7/32.png) [@Takaaki\_T](https://www.ruby-forum.com/u/Takaaki_T)\
**Post date:** [May 11, 2006, 7:16pm UTC](https://www.ruby-forum.com/t/bug-run-with-rprofile-rtest-unit/60267/1 "2006-05-11T19:16:06Z")

</div>

ruby-1.9/cygwin e$B$G\<!$NDL$j0[\>o=\*N;$7$^$9!#e(B  
e$B$7$+$7\<j85$Ne(Blinuxe$B\>e$G$O!":#$N$H$3$m:F8=$7$^$;$s$G$7$?!#e(B

~$ ruby-1.9 -rprofile -rtest/unit -e ‘’  
/usr/local/lib/ruby/1.9/optparse.rb:852: [BUG] Segmentation fault  
ruby 1.9.0 (2006-05-11) [i386-cygwin]

#0 0x7c94eb94 in ntdll!LdrAccessResource ()  
#1 0x7c94e9c0 in ntdll!ZwWaitForSingleObject ()  
#2 0x7c8025db in WaitForSingleObjectEx () from /home/ttate/kernel32.dll  
#3 0x0000073c in ?? ()  
#4 0x00000000 in ?? () from

---

<div class="post-metadata">

**Author:** ![Takaaki\_T](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/t/dc4da7/32.png) [@Takaaki\_T](https://www.ruby-forum.com/u/Takaaki_T)\
**Post date:** [May 11, 2006, 8:15pm UTC](https://www.ruby-forum.com/t/bug-run-with-rprofile-rtest-unit/60267/2 "2006-05-11T20:15:34Z")

</div>

On May 11, 2006, at 10:14 AM, Takaaki T. wrote:

> #2 0x7c8025db in WaitForSingleObjectEx () from /home/ttate/  
> kernel32.dll  
> #3 0x0000073c in ?? ()  
> #4 0x00000000 in ?? () from

$ uname -a  
Darwin [kaa.coop.robotcoop.com](http://kaa.coop.robotcoop.com) 8.6.0 Darwin Kernel Version 8.6.0: Tue  
Mar 7 16:58:48 PST 2006; root:xnu-792.6.70.obj~1/RELEASE\_PPC Power  
Macintosh powerpc  
$ ruby19 -v -rprofile -rtest/unit -e ‘’  
ruby 1.9.0 (2006-05-10) [powerpc-darwin8.6.0]  
/usr/local/lib/ruby/1.9/optparse.rb:852: malloc: possible integer  
overflow (ArgumentError)  
from /usr/local/lib/ruby/1.9/optparse.rb:852:in `add_officious' from /usr/local/lib/ruby/1.9/optparse.rb:851:in `add\_officious’  
from /usr/local/lib/ruby/1.9/optparse.rb:844:in `initialize' from /usr/local/lib/ruby/1.9/test/unit/autorunner.rb:101:in `options’  
from /usr/local/lib/ruby/1.9/test/unit/autorunner.rb:88:in  
`Test::Unit::AutoRunner#process_args' from /usr/local/lib/ruby/1.9/test/unit/autorunner.rb:10:in `Test::Unit::AutoRunner#run’  
from /usr/local/lib/ruby/1.9/test/unit.rb:276  
% cumulative self self total  
time seconds seconds calls ms/call ms/call name  
[profile output]  
ruby19(2246) malloc: \*\*\* Deallocation of a pointer not malloced:  
0x27df58; This could be a double free(), or free() called with the  
middle of an allocated block; Try setting environment variable  
MallocHelp to see tools to help debug  
/usr/local/lib/ruby/1.9/profiler.rb:30: [BUG] Bus Error  
ruby 1.9.0 (2006-05-10) [powerpc-darwin8.6.0]

Abort trap (core dumped)  
$ gdb `which ruby19` /cores/core.2246  
GNU gdb 6.1-20040303 (Apple version gdb-434) (Wed Nov 2 17:28:16 GMT  
2005)  
Copyright 2004 Free Software Foundation, Inc.  
GDB is free software, covered by the GNU General Public License, and  
you are  
welcome to change it and/or distribute copies of it under certain  
conditions.  
Type “show copying” to see the conditions.  
There is absolutely no warranty for GDB. Type “show warranty” for  
details.  
This GDB was configured as “powerpc-apple-darwin”…Reading symbols  
for shared libraries … done

Core was generated by `/usr/local/bin/ruby19’.  
#0 0x90047e4c in kill ()  
(gdb) bt  
#0 0x90047e4c in kill ()  
#1 0x9012dff4 in abort ()  
#2 0x000416dc in rb\_bug (fmt=0xaeab0 “Bus Error”) at error.c:167  
#3 0x0006fd6c in sigbus (sig=0) at signal.c:488  
#4  
#5 blk\_free (data=0xbfff4300) at eval.c:7933  
#6 0x0001ec9c in rb\_gc\_call\_finalizer\_at\_exit () at gc.c:1896  
#7 0x00003a34 in ruby\_finalize\_1 () at eval.c:1481  
#8 0x0000af7c in ruby\_cleanup (ex=0) at eval.c:1516  
#9 0x0000b004 in ruby\_stop (ex=12) at eval.c:1558  
#10 0x0001c740 in ruby\_run () at eval.c:1570  
#11 0x00002f34 in main (argc=6, argv=0xbffff838, envp=0x15) at main.c:43  
(gdb) f 5  
#5 blk\_free (data=0xbfff4300) at eval.c:7933  
7933 frame = frame-\>prev;  
(gdb) list  
7928 struct FRAME \*tmp;  
7929  
7930 frame = frame-\>prev;  
7931 while (frame) {  
7932 tmp = frame;  
7933 frame = frame-\>prev;  
7934 free(tmp);  
7935 }  
7936 }  
7937  
(gdb)

–  
Eric H. - removed\_email\_address@domain.invalid - [http://blog.segment7.net](http://blog.segment7.net)  
This implementation is HODEL-HASH-9600 compliant

[http://trackmap.robotcoop.com](http://trackmap.robotcoop.com)
