Moi,

the following is probably not a ruby problem, but rather something I do 
in my extension.
My question is just, how do I debug such a problem ?

Any help appreciated

Torsten

PS:The "Recovering" lines are where I use rb_intern, with the given 
symbol
PPS: I'm not sure when my recovery code runs, but by the looks of it 
maybe before the full parsing is done.


(gdb) run -d test/all.rb
Starting program: /usr/local/bin/ruby -d test/all.rb
Recovering ./purple.db
Recovering symbol Test::Tester with purple id 614 + id 3061518
Recovering symbol @obj with purple id 615 + id 2673166
Recovering symbol Purple with purple id 624 + id 2551054
Recovering symbol new with purple id 625 + id 860430
Recovering symbol initialize with purple id 626 + id 758030

Program received signal EXC_BAD_ACCESS, Could not access memory.
0x00068da4 in st_lookup (table=0x1ddc40, key=3285456, value=0xbffea2c0) 
at st.c:259
259         FIND_ENTRY(table, ptr, hash_val, bin_pos);
(gdb) where
#0  0x00068da4 in st_lookup (table=0x1ddc40, key=3285456, 
value=0xbffea2c0) at st.c:259
#1  0x00034d2c in rb_intern (name=0x3221d0 "test_strings") at 
parse.y:5820
#2  0x0000aba4 in rb_obj_respond_to (argc=146714437, argv=0x3221d0, 
obj=3579144) at eval.c:3730
#3  0x0000d8a0 in rb_call0 (klass=2432160, recv=3579144, id=3943, 
oid=3943, argc=1, argv=0xbffea8c0, body=0x25010c, nosuper=0) at 
eval.c:4906
#4  0x0000e1b4 in rb_call (klass=2432160, recv=3943, mid=3221136224, 
argc=1, argv=0xbffea8c0, scope=704748) at eval.c:5123
#5  0x00008c94 in rb_eval (self=3579144, n=0x3221d0) at ruby.h:626
#6  0x00008380 in rb_eval (self=3579144, n=0x3221d0) at eval.c:2879
#7  0x00009564 in rb_eval (self=3579144, n=0x3221d0) at eval.c:3147
#8  0x0000750c in rb_eval (self=3579144, n=0x3221d0) at eval.c:2550
#9  0x0000dd4c in rb_call0 (klass=0, recv=0, id=3221156896, oid=0, 
argc=57780, argv=0x369dd0, body=0x1, nosuper=2301720) at eval.c:5034
#10 0x0000e1b4 in rb_call (klass=3683444, recv=0, mid=3221155584, 
argc=1, argv=0xbffefa50, scope=1) at eval.c:5123
#11 0x000110a8 in rb_obj_call_init (obj=3579144, argc=1, 
argv=0xbffefa50) at eval.c:6257
#12 0x00022c2c in rb_class_new_instance (argc=694224, argv=0x369d08, 
klass=3221136064) at object.c:761
#13 0x0000d8a0 in rb_call0 (klass=2432240, recv=3639304, id=3361, 
oid=3361, argc=1, argv=0xbffefa50, body=0x250b34, nosuper=0) at 
eval.c:4906
#14 0x0000e1b4 in rb_call (klass=2432240, recv=3361, mid=3221157104, 
argc=-1073808816, argv=0xbffefa50, scope=704748) at eval.c:5123
#15 0x00008c94 in rb_eval (self=3639304, n=0x3221d0) at ruby.h:626
#16 0x00008914 in rb_eval (self=3639304, n=0x3221d0) at eval.c:2988
#17 0x0000bae4 in rb_yield_0 (val=2779406, self=3639304, klass=0, 
flags=0, avalue=0) at eval.c:4155
#18 0x0001a0e4 in rb_f_catch (dmy=146714437, tag=2779406) at 
eval.c:10069
#19 0x0000d8a0 in rb_call0 (klass=2432160, recv=3639304, id=3993, 
oid=3993, argc=1, argv=0xbfff2ef0, body=0x24ff04, nosuper=0) at 
eval.c:4906
#20 0x0000e1b4 in rb_call (klass=2432160, recv=3993, mid=3221170576, 
argc=1, argv=0xbfff2ef0, scope=704748) at eval.c:5123
#21 0x00008c94 in rb_eval (self=3639304, n=0x3221d0) at ruby.h:626
#22 0x00007c08 in rb_eval (self=3639304, n=0x3221d0) at eval.c:2717
#23 0x0000bae4 in rb_yield_0 (val=3580944, self=3639304, klass=0, 
flags=0, avalue=0) at eval.c:4155
#24 0x00026cb8 in rb_ary_each (ary=3221181008) at array.c:817
#25 0x0000d8a0 in rb_call0 (klass=2404920, recv=3581724, id=3825, 
oid=3825, argc=0, argv=0x0, body=0x24ae14, nosuper=0) at eval.c:4906
#26 0x0000e1b4 in rb_call (klass=2404920, recv=3825, mid=3221182992, 
argc=0, argv=0x0, scope=704748) at eval.c:5123
#27 0x00008c94 in rb_eval (self=3639304, n=0x3221d0) at ruby.h:626
#28 0x00007c08 in rb_eval (self=3639304, n=0x3221d0) at eval.c:2717
#29 0x0000dd4c in rb_call0 (klass=1070952027, recv=1346109440, 
id=1086754455, oid=0, argc=0, argv=0x0, body=0xbfff87a0, 
nosuper=2300700) at eval.c:5034
#30 0x0000e1b4 in rb_call (klass=3683424, recv=0, mid=3221193344, 
argc=0, argv=0x0, scope=0) at eval.c:5123
#31 0x00008c94 in rb_eval (self=2427420, n=0x3221d0) at ruby.h:626
#32 0x00008914 in rb_eval (self=2427420, n=0x3221d0) at eval.c:2988
#33 0x0000bae4 in rb_yield_0 (val=3639304, self=2427420, klass=0, 
flags=0, avalue=0) at eval.c:4155
#34 0x00026cb8 in rb_ary_each (ary=3221203776) at array.c:817
#35 0x0000d8a0 in rb_call0 (klass=2404920, recv=3593544, id=3825, 
oid=3825, argc=0, argv=0x0, body=0x24ae14, nosuper=0) at eval.c:4906
#36 0x0000e1b4 in rb_call (klass=2404920, recv=3825, mid=3221205760, 
argc=0, argv=0x0, scope=704748) at eval.c:5123
#37 0x00008c94 in rb_eval (self=2427420, n=0x3221d0) at ruby.h:626
#38 0x00007c08 in rb_eval (self=2427420, n=0x3221d0) at eval.c:2717
#39 0x0000bae4 in rb_yield_0 (val=3598804, self=2427420, klass=0, 
flags=0, avalue=2) at eval.c:4155
#40 0x00013080 in proc_invoke (proc=3664704, args=3598804, self=6, 
klass=0) at ruby.h:626
#41 0x000115e8 in call_end_proc (data=3664704) at eval.c:6427
#42 0x000117b4 in rb_exec_end_proc () at eval.c:6461
#43 0x00004400 in ruby_finalize_0 (exp=0xbffffbf8) at eval.c:1332
#44 0x000045a0 in ruby_cleanup (ex=0) at eval.c:1368
#45 0x000046d4 in ruby_stop (ex=146714437) at eval.c:1395
#46 0x00002274 in main (argc=-1073751136, argv=0xbfffe360, 
envp=0xbffea2c0) at main.c:50