mgcaret / hexchat-mruby Goto Github PK
View Code? Open in Web Editor NEWEmbedded MRuby for HexChat IRC Client
Embedded MRuby for HexChat IRC Client
After basic changes made to properly compile with MRuby 2.0.0+, loading a script does not work, with a SEGV in vm.c: mrb->c->stack[0] = recv;
1490 irep = proc->body.irep;
1491 pool = irep->pool;
1492 syms = irep->syms;
1493 }
1494 }
1495 mrb->c->stack[0] = recv;
1496 /* pop stackpos */
1497 mrb->c->stack = ci->stackent;
1498 pc = ci->pc;
1499 cipop(mrb);
The script runs, but crashes when returning from the C method implementing HexChat::Internal.load()
If the script file does not exist or a syntax error occurs, no crash occurs.
GDB output:
(4) [STDO/RITE]
00001 NODE_SCOPE:
00001 NODE_BEGIN:
00001 NODE_CALL(.):
00001 NODE_CONST STDOUT
00001 method='puts' (2710343)
00001 args:
00001 NODE_STR "loaded it!" len 10
irep 0x12fc710 nregs=4 nlocals=1 pools=1 syms=2 reps=0 iseq=13
file: /home/mg/.config/hexchat/mruby/test/test.rb
1 000 OP_GETCONST R1 :STDOUT
1 003 OP_STRING R2 L(0) ; "loaded it!"
1 006 OP_SEND R1 :puts 1
1 010 OP_RETURN R1
1 012 OP_STOP
loaded it!
Program received signal SIGSEGV, Segmentation fault.
0x00007fffdfda14c1 in mrb_vm_exec (mrb=0x136b6c0, proc=0x141a650, pc=0x7fffdfead3e6 <hexchat_mrb_lib+14342> "!")
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:1495
1495 mrb->c->stack[0] = recv;
Backtrace:
#0 0x00007fffdfda14c1 in mrb_vm_exec (mrb=0x136b6c0, proc=0x141a650, pc=0x7fffdfead3e6 <hexchat_mrb_lib+14342> "!")
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:1495
#1 0x00007fffdfd9e390 in mrb_vm_run (mrb=0x136b6c0, proc=0x13b0450, self=..., stack_keep=4)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:978
#2 0x00007fffdfdae9b9 in mrb_run (mrb=0x136b6c0, proc=0x13b0450, self=...)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:3007
#3 0x00007fffdfd9d0a1 in mrb_funcall_with_block (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300, blk=...) at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:533
#4 0x00007fffdfd9c95a in mrb_funcall_with_block (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300, blk=...) at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:439
#5 0x00007fffdfd9d124 in mrb_funcall_argv (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:543
#6 0x00007fffdfd9c7a9 in mrb_funcall (mrb=0x136b6c0, self=..., name=0x7fffdfeb1ce9 "mrb_command", argc=2)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:400
#7 0x00007fffdfd6c6ca in hex_mrb_command_eval (word=0x7fffffffb770, word_eol=0x7fffffffb660, mrb=0x136b6c0)
at mruby.c:1162
#8 0x00000000004890c6 in plugin_hook_run (sess=0x770840, name=0x11fd570 "mrb", word=0x7fffffffb770, word_eol=0x7fffffffb660, attrs=0x0, type=1) at plugin.c:562
#9 0x0000000000489268 in plugin_emit_command (sess=0x770840, name=0x11fd570 "mrb", word=0x7fffffffb770, word_eol=0x7fffffffb660) at plugin.c:614
#10 0x000000000048808c in handle_command (sess=0x770840, cmd=0x1480301 "mrb load test/test.rb", check_spch=1)
at outbound.c:4696
#11 0x00000000004883af in handle_user_input (sess=0x770840, text=0x1480300 "/mrb load test/test.rb", history=1, nocommand=0) at outbound.c:4830
#12 0x0000000000488417 in handle_multiline (sess=0x770840, cmd=0x1480300 "/mrb load test/test.rb", history=1, nocommand=0) at outbound.c:4842
#13 0x000000000043bb9a in mg_inputbox_cb (igad=0x7891e0, gui=0x6dbac0 <static_mg_gui>) at maingui.c:341
#14 0x00007ffff59c3add in g_closure_invoke () at /lib64/libgobject-2.0.so.0
#15 0x00007ffff59d6f43 in signal_emit_unlocked_R () at /lib64/libgobject-2.0.so.0
#16 0x00007ffff59df19f in g_signal_emitv () at /lib64/libgobject-2.0.so.0
#17 0x00007ffff77ca724 in gtk_binding_entry_activate () at /lib64/libgtk-x11-2.0.so.0
#18 0x00007ffff77cabe1 in binding_match_activate () at /lib64/libgtk-x11-2.0.so.0
#19 0x00007ffff77cae7f in gtk_bindings_activate_list () at /lib64/libgtk-x11-2.0.so.0
#20 0x00007ffff77cc00e in gtk_bindings_activate_event () at /lib64/libgtk-x11-2.0.so.0
Additional info:
(gdb) info args
mrb = 0x136b6c0
proc = 0x141a650
pc = 0x7fffdfead3e6 <hexchat_mrb_lib+14342> "!"
(gdb) info locals
m = {func_p = 1 '\001', {proc = 0x7fffdfd6a150 <hex_mrb_xi_load>, func = 0x7fffdfd6a150 <hex_mrb_xi_load>}}
ci = 0x1398ce0
recv = {value = {f = 4.9406564584124654e-324, p = 0x1, i = 1, sym = 1}, tt = MRB_TT_TRUE}
blk = {value = {f = 0, p = 0x0, i = 0, sym = 0}, tt = MRB_TT_FALSE}
argc = 1
bidx = 7
cls = 0x13b4680
pc0 = 0x7fffdfead3e2 <hexchat_mrb_lib+14338> ".\005\a\001!"
irep = 0x1442a80
pool = 0x1442ad0
syms = 0x1442db0
insn = 46 '.'
ai = 24
prev_jmp = 0x7fffffffb0e0
c_jmp = {impl = {{__jmpbuf = {16, 5813337038024502804, 1, 21360656, 140737488337600, 140737346363040,
5813337037661695508, 5813407631888641556}, __mask_was_saved = 0, __saved_mask = {__val = {140737488333600,
13873200, 498, 140737488333456, 0, 7338768, 140737488333504, 7371168, 4294968294, 4311744512, 0, 0,
7250832, 140737316412240, 7250832, 140737316412240}}}}}
a = 5
b = 7
c = 1 '\001'
mid = 665655
optable = {0x7fffdfd9e613 <mrb_vm_exec+306>, 0x7fffdfd9e65c <mrb_vm_exec+379>, 0x7fffdfd9e715 <mrb_vm_exec+564>,
0x7fffdfd9e7c6 <mrb_vm_exec+741>, 0x7fffdfd9e87e <mrb_vm_exec+925>, 0x7fffdfd9e93d <mrb_vm_exec+1116>,
0x7fffdfd9e978 <mrb_vm_exec+1175>, 0x7fffdfd9e9b3 <mrb_vm_exec+1234>, 0x7fffdfd9e9ee <mrb_vm_exec+1293>,
0x7fffdfd9ea29 <mrb_vm_exec+1352>, 0x7fffdfd9ea64 <mrb_vm_exec+1411>, 0x7fffdfd9ea9f <mrb_vm_exec+1470>,
0x7fffdfd9ead4 <mrb_vm_exec+1523>, 0x7fffdfd9eb09 <mrb_vm_exec+1576>, 0x7fffdfd9eba9 <mrb_vm_exec+1736>,
0x7fffdfd9ec72 <mrb_vm_exec+1937>, 0x7fffdfd9ed0e <mrb_vm_exec+2093>, 0x7fffdfd9eda0 <mrb_vm_exec+2239>,
0x7fffdfd9ee3c <mrb_vm_exec+2395>, 0x7fffdfd9eed8 <mrb_vm_exec+2551>, 0x7fffdfd9efb3 <mrb_vm_exec+2770>,
0x7fffdfd9f072 <mrb_vm_exec+2961>, 0x7fffdfd9f13c <mrb_vm_exec+3163>, 0x7fffdfd9f1ea <mrb_vm_exec+3337>,
0x7fffdfd9f2bd <mrb_vm_exec+3548>, 0x7fffdfd9f399 <mrb_vm_exec+3768>, 0x7fffdfd9f4a2 <mrb_vm_exec+4033>,
0x7fffdfd9f561 <mrb_vm_exec+4224>, 0x7fffdfd9f676 <mrb_vm_exec+4501>, 0x7fffdfd9f735 <mrb_vm_exec+4692>,
0x7fffdfd9f85c <mrb_vm_exec+4987>, 0x7fffdfd9f947 <mrb_vm_exec+5222>, 0x7fffdfd9fa79 <mrb_vm_exec+5528>,
0x7fffdfd9fbb4 <mrb_vm_exec+5843>, 0x7fffdfd9fc3e <mrb_vm_exec+5981>, 0x7fffdfd9fd30 <mrb_vm_exec+6223>,
0x7fffdfd9fe22 <mrb_vm_exec+6465>, 0x7fffdfd9ff35 <mrb_vm_exec+6740>, 0x7fffdfda0171 <mrb_vm_exec+7312>,
0x7fffdfda022c <mrb_vm_exec+7499>, 0x7fffdfda03f4 <mrb_vm_exec+7955>, 0x7fffdfda047d <mrb_vm_exec+8092>,
0x7fffdfda04e5 <mrb_vm_exec+8196>, 0x7fffdfda077b <mrb_vm_exec+8858>, 0x7fffdfda0aa3 <mrb_vm_exec+9666>,
0x7fffdfda0af9 <mrb_vm_exec+9752>, 0x7fffdfda0b4f <mrb_vm_exec+9838>, 0x7fffdfda0c93 <mrb_vm_exec+10162>,
0x7fffdfda15eb <mrb_vm_exec+12554>, 0x7fffdfda1a7f <mrb_vm_exec+13726>, 0x7fffdfda24f6 <mrb_vm_exec+16405>,
0x7fffdfda2bfb <mrb_vm_exec+18202>, 0x7fffdfda39c7 <mrb_vm_exec+21734>, 0x7fffdfda3b1d <mrb_vm_exec+22076>,
0x7fffdfda3798 <mrb_vm_exec+21175>, 0x7fffdfda3d49 <mrb_vm_exec+22632>, 0x7fffdfda3d12 <mrb_vm_exec+22577>,
0x7fffdfda3cdb <mrb_vm_exec+22522>, 0x7fffdfda4d4c <mrb_vm_exec+26731>, 0x7fffdfda4fe7 <mrb_vm_exec+27398>,
0x7fffdfda5e15 <mrb_vm_exec+31028>, 0x7fffdfda53dd <mrb_vm_exec+28412>, 0x7fffdfda6067 <mrb_vm_exec+31622>,
0x7fffdfda5760 <mrb_vm_exec+29311>, 0x7fffdfda5ae3 <mrb_vm_exec+30210>, 0x7fffdfda6220 <mrb_vm_exec+32063>,
0x7fffdfda65c6 <mrb_vm_exec+32997>, 0x7fffdfda68a5 <mrb_vm_exec+33732>, 0x7fffdfda6b84 <mrb_vm_exec+34467>,
0x7fffdfda6e63 <mrb_vm_exec+35202>, 0x7fffdfda7142 <mrb_vm_exec+35937>, 0x7fffdfda723a <mrb_vm_exec+36185>,
0x7fffdfda734b <mrb_vm_exec+36458>, 0x7fffdfda7440 <mrb_vm_exec+36703>, 0x7fffdfda74f3 <mrb_vm_exec+36882>,
0x7fffdfda7665 <mrb_vm_exec+37252>, 0x7fffdfda7809 <mrb_vm_exec+37672>, 0x7fffdfda78f7 <mrb_vm_exec+37910>,
0x7fffdfda7d24 <mrb_vm_exec+38979>, 0x7fffdfda7dfa <mrb_vm_exec+39193>, 0x7fffdfda7eee <mrb_vm_exec+39437>,
0x7fffdfda7fa1 <mrb_vm_exec+39616>, 0x7fffdfda812c <mrb_vm_exec+40011>, 0x7fffdfda82aa <mrb_vm_exec+40393>,
0x7fffdfda839f <mrb_vm_exec+40638>, 0x7fffdfda8526 <mrb_vm_exec+41029>, 0x7fffdfda857c <mrb_vm_exec+41115>,
0x7fffdfda85d2 <mrb_vm_exec+41201>, 0x7fffdfda86dc <mrb_vm_exec+41467>, 0x7fffdfda87e6 <mrb_vm_exec+41733>,
0x7fffdfda8876 <mrb_vm_exec+41877>, 0x7fffdfda8a8b <mrb_vm_exec+42410>, 0x7fffdfda8c58 <mrb_vm_exec+42871>,
0x7fffdfda8f50 <mrb_vm_exec+43631>, 0x7fffdfda91e9 <mrb_vm_exec+44296>, 0x7fffdfda92d1 <mrb_vm_exec+44528>,
0x7fffdfda9077 <mrb_vm_exec+43926>, 0x7fffdfda913a <mrb_vm_exec+44121>, 0x7fffdfda938b <mrb_vm_exec+44714>,
0x7fffdfda9439 <mrb_vm_exec+44888>, 0x7fffdfda9525 <mrb_vm_exec+45124>, 0x7fffdfdab253 <mrb_vm_exec+52594>,
0x7fffdfdacad1 <mrb_vm_exec+58864>, 0x7fffdfdae856 <mrb_vm_exec+66421>}
exc_catched = 0 '\000'
__PRETTY_FUNCTION__ = "mrb_vm_exec"
(gdb) bt full
#0 0x00007fffdfda14c1 in mrb_vm_exec (mrb=0x136b6c0, proc=0x141a650, pc=0x7fffdfead3e6 <hexchat_mrb_lib+14342> "!")
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:1495
m = {func_p = 1 '\001', {proc = 0x7fffdfd6a150 <hex_mrb_xi_load>, func = 0x7fffdfd6a150 <hex_mrb_xi_load>}}
ci = 0x1398ce0
recv = {value = {f = 4.9406564584124654e-324, p = 0x1, i = 1, sym = 1}, tt = MRB_TT_TRUE}
blk = {value = {f = 0, p = 0x0, i = 0, sym = 0}, tt = MRB_TT_FALSE}
argc = 1
bidx = 7
cls = 0x13b4680
pc0 = 0x7fffdfead3e2 <hexchat_mrb_lib+14338> ".\005\a\001!"
irep = 0x1442a80
pool = 0x1442ad0
syms = 0x1442db0
insn = 46 '.'
ai = 24
prev_jmp = 0x7fffffffb0e0
c_jmp =
{impl = {{__jmpbuf = {16, 5813337038024502804, 1, 21360656, 140737488337600, 140737346363040, 5813337037661695508, 5813407631888641556}, __mask_was_saved = 0, __saved_mask = {__val = {140737488333600, 13873200, 498, 140737488333456, 0, 7338768, 140737488333504, 7371168, 4294968294, 4311744512, 0, 0, 7250832, 140737316412240, 7250832, 140737316412240}}}}}
a = 5
b = 7
c = 1 '\001'
mid = 665655
optable =
{0x7fffdfd9e613 <mrb_vm_exec+306>, 0x7fffdfd9e65c <mrb_vm_exec+379>, 0x7fffdfd9e715 <mrb_vm_exec+564>, 0x7fffdfd9e7c6 <mrb_vm_exec+741>, 0x7fffdfd9e87e <mrb_vm_exec+925>, 0x7fffdfd9e93d <mrb_vm_exec+1116>, 0x7fffdfd9e978 <mrb_vm_exec+1175>, 0x7fffdfd9e9b3 <mrb_vm_exec+1234>, 0x7fffdfd9e9ee <mrb_vm_exec+1293>, 0x7fffdfd9ea29 <mrb_vm_exec+1352>, 0x7fffdfd9ea64 <mrb_vm_exec+1411>, 0x7fffdfd9ea9f <mrb_vm_exec+1470>, 0x7fffdfd9ead4 <mrb_vm_exec+1523>, 0x7fffdfd9eb09 <mrb_vm_exec+1576>, 0x7fffdfd9eba9 <mrb_vm_exec+1736>, 0x7fffdfd9ec72 <mrb_vm_exec+1937>, 0x7fffdfd9ed0e <mrb_vm_exec+2093>, 0x7fffdfd9eda0 <mrb_vm_exec+2239>, 0x7fffdfd9ee3c <mrb_vm_exec+2395>, 0x7fffdfd9eed8 <mrb_vm_exec+2551>, 0x7fffdfd9efb3 <mrb_vm_exec+2770>, 0x7fffdfd9f072 <mrb_vm_exec+2961>, 0x7fffdfd9f13c <mrb_vm_exec+3163>, 0x7fffdfd9f1ea <mrb_vm_exec+3337>, 0x7fffdfd9f2bd <mrb_vm_exec+3548>, 0x7fffdfd9f399 <mrb_vm_exec+3768>, 0x7fffdfd9f4a2 <mrb_vm_exec+4033>, 0---Type <return> to continue, or q <return> to quit---
x7fffdfd9f561 <mrb_vm_exec+4224>, 0x7fffdfd9f676 <mrb_vm_exec+4501>, 0x7fffdfd9f735 <mrb_vm_exec+4692>, 0x7fffdfd9f85c <mrb_vm_exec+4987>, 0x7fffdfd9f947 <mrb_vm_exec+5222>, 0x7fffdfd9fa79 <mrb_vm_exec+5528>, 0x7fffdfd9fbb4 <mrb_vm_exec+5843>, 0x7fffdfd9fc3e <mrb_vm_exec+5981>, 0x7fffdfd9fd30 <mrb_vm_exec+6223>, 0x7fffdfd9fe22 <mrb_vm_exec+6465>, 0x7fffdfd9ff35 <mrb_vm_exec+6740>, 0x7fffdfda0171 <mrb_vm_exec+7312>, 0x7fffdfda022c <mrb_vm_exec+7499>, 0x7fffdfda03f4 <mrb_vm_exec+7955>, 0x7fffdfda047d <mrb_vm_exec+8092>, 0x7fffdfda04e5 <mrb_vm_exec+8196>, 0x7fffdfda077b <mrb_vm_exec+8858>, 0x7fffdfda0aa3 <mrb_vm_exec+9666>, 0x7fffdfda0af9 <mrb_vm_exec+9752>, 0x7fffdfda0b4f <mrb_vm_exec+9838>, 0x7fffdfda0c93 <mrb_vm_exec+10162>, 0x7fffdfda15eb <mrb_vm_exec+12554>, 0x7fffdfda1a7f <mrb_vm_exec+13726>, 0x7fffdfda24f6 <mrb_vm_exec+16405>, 0x7fffdfda2bfb <mrb_vm_exec+18202>, 0x7fffdfda39c7 <mrb_vm_exec+21734>, 0x7fffdfda3b1d <mrb_vm_exec+22076>, 0x7fffdfda3798 <mrb_vm_exec+21175>, 0x7fffdfda3d49 <mrb_vm_exec+22632>, 0x7fffdfda3d12 <mrb_vm_exec+22577>, 0x7fffdfda3cdb <mrb_vm_exec+22522>, 0x7fffdfda4d4c <mrb_vm_exec+26731>, 0x7fffdfda4fe7 <mrb_vm_exec+27398>, 0x7fffdfda5e15 <mrb_vm_exec+31028>, 0x7fffdfda53dd <mrb_vm_exec+28412>, 0x7fffdfda6067 <mrb_vm_exec+31622>, 0x7fffdfda5760 <mrb_vm_exec+29311>, 0x7fffdfda5ae3 <mrb_vm_exec+30210>, 0x7fffdfda6220 <mrb_vm_exec+32063>, 0x7fffdfda65c6 <mrb_vm_exec+32997>, 0x7fffdfda68a5 <mrb_vm_exec+33732>, 0x7fffdfda6b84 <mrb_vm_exec+34467>, 0x7fffdfda6e63 <mrb_vm_exec+35202>, 0x7fffdfda7142 <mrb_vm_exec+35937>, 0x7fffdfda723a <mrb_vm_exec+36185>, 0x7fffdfda734b <mrb_vm_exec+36458>, 0x7fffdfda7440 <mrb_vm_exec+36703>, 0x7fffdfda74f3 <mrb_vm_exec+36882>, 0x7fffdfda7665 <mrb_vm_exec+37252>, 0x7fffdfda7809 <mrb_vm_exec+37672>, 0x7fffdfda78f7 <mrb_vm_exec+37910>, 0x7fffdfda7d24 <mrb_vm_exec+38979>, 0x7fffdfda7dfa <mrb_vm_exec+39193>, 0x7fffdfda7eee <mrb_vm_exec+39437>, 0x7fffdfda7fa1 <mrb_vm_exec+39616>, 0x7fffdfda812c <mrb_vm_exec+40011>, 0x7fffdfda82aa <mrb_vm_exec+40393>, 0x7fffdfda839f <mrb_vm_exec+40638>, 0x7fffdfda8526 <mrb_vm_exec+41029>, 0x7fffdfda857c <mrb_vm_exec+41115>, 0x7fffdfda85d2 <mrb_vm_exec+41201>, 0x7fffdfda86dc <mrb_vm_exec+41467>, 0x7fffdfda87e6 <mrb_vm_exec+41733>, 0x7fffdfda8876 <mrb_vm_exec+41877>, 0x7fffdfda8a8b <mrb_vm_exec+42410>, 0x7fffdfda8c58 <mrb_vm_exec+42871>, 0x7fffdfda8f50 <mrb_vm_exec+43631>, 0x7fffdfda91e9 <mrb_vm_exec+44296>, 0x7fffdfda92d1 <mrb_vm_exec+44528>, 0x7fffdfda9077 <mrb_vm_exec+43926>, 0x7fffdfda913a <mrb_vm_exec+44121>, 0x7fffdfda938b <mrb_vm_exec+44714>, 0x7fffdfda9439 <mrb_vm_exec+44888>, 0x7fffdfda9525 <mrb_vm_exec+45124>, 0x7fffdfdab253 <mrb_vm_exec+52594>, 0x7fffdfdacad1 <mrb_vm_exec+58864>, 0x7fffdfdae856 <mrb_vm_exec+66421>}
exc_catched = 0 '\000'
__PRETTY_FUNCTION__ = "mrb_vm_exec"
#1 0x00007fffdfd9e390 in mrb_vm_run (mrb=0x136b6c0, proc=0x13b0450, self=..., stack_keep=4)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:978
irep = 0x143eb20
result = {value = {f = 4.2838179211549452e-317, p = 0x844d50, i = 8670544, sym = 8670544}, tt = 3112155648}
c = 0x1316bf0
cioff = 1
nregs = 10
#2 0x00007fffdfdae9b9 in mrb_run (mrb=0x136b6c0, proc=0x13b0450, self=...)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:3007
#3 0x00007fffdfd9d0a1 in mrb_funcall_with_block (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300, blk=...) at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:533
m = {func_p = 0 '\000', {proc = 0x13b0450, func = 0x13b0450}}
c = 0x13b4680
ci = 0x1398c98
n = 4
voff = -1
val = {value = {f = 1.0621399539144118e-316, p = 0x1480860, i = 21497952, sym = 21497952}, tt = 4117782481}
#4 0x00007fffdfd9c95a in mrb_funcall_with_block (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300, blk=...) at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:439
c_jmp =
{impl = {{__jmpbuf = {16, 5813337038429253140, 1, 21360656, 140737488337600, 140737346363040, 5813337038357949972, 5813407631223189012}, __mask_was_saved = 0, __saved_mask = {__val = {21507104, 16, 21497760, 21504144, 1, 21497760, 140737311073406, 1, 21504168, 691, 140737342306101, 47266144400, 140736950115561, 21504144, 4294967987, 140737342301408}}}}}
nth_ci = 0
val = {value = {f = 1.0447891589375006e-316, p = 0x142ac90, i = 21146768, sym = 21146768}, tt = MRB_TT_ICLASS}
#5 0x00007fffdfd9d124 in mrb_funcall_argv (mrb=0x136b6c0, self=..., mid=2412, argc=2, argv=0x7fffffffb300)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:543
#6 0x00007fffdfd9c7a9 in mrb_funcall (mrb=0x136b6c0, self=..., name=0x7fffdfeb1ce9 "mrb_command", argc=2)
at /home/mg/proj/hexchat-mruby/mruby/src/vm.c:400
argv =
{{value = {f = 1.040490392566165e-316, p = 0x14158b0, i = 21059760, sym = 21059760}, tt = MRB_TT_ARRAY}, {value = {f = 1.0404809065057649e-316, p = 0x14157f0, i = 21059568, sym = 21059568}, tt = MRB_TT_ARRAY}, {value = {f = 6.9533558068658452e-310, p = 0x7fffffffb360, i = 140737488335712, sym = 4294947680}, tt = 3755565929}, {value = {f = 4.4614127819464563e-321, p = 0x387, i = 903, sym = 903}, tt = 64}, {value = {f = 0, p = 0x0, i = 0, sym = 0}, tt = 20362944}, {value = {f = 6.9533558068707858e-310, p = 0x7fffffffb3c4, i = 140737488335812, sym = 4294947780}, tt = 21501744}, {value = {f = 6.9533558068697977e-310, p = 0x7fffffffb3b0, i = 140737488335792, sym = 4294947760}, tt = 3755566059}, {value = {f = 6.9533558068729597e-310, p = 0x7fffffffb3f0, i = 140737488335856, sym = 4294947824}, tt = 64}, {value = {f = 0, p = 0x0, i = 0, sym = 0}, tt = 21059424}, {value = {f = 1.0060729891718305e-316, p = 0x136b788, i = 20363144, sym = 20363144}, tt = 20362944}, {value = {f = 6.9533558068745407e-310, p = 0x7fffffffb410, i = 140737488335888, sym = 4294947856}, tt = 3755569134}, {value = {f = 1.0404820922633149e-316, p = 0x1415808, i = 21059592, sym = 21059592}, tt = 20690352}, {value = {f = 3.3951932687064558e-313, p = 0x1000000040, i = 68719476800, sym = 64}, tt = 20362944}, {value = {f = 6.95
33558068761217e-310, p = 0x7fffffffb430, i = 140737488335920, sym = 4294947888}, tt = 21059424}, {value = {f = 1.0404809065057649e-316, p = 0x14157f0, i = 21059568, sym = 21059568}, tt = 20362944}, {value = {f = 6.9533558068761217e-310, p = 0x7fffffffb430, i = 140737488335920, sym = 4294947888}, tt = 3755445332}}
ap = {{gp_offset = 40, fp_offset = 48, overflow_arg_area = 0x7fffffffb4f0, reg_save_area = 0x7fffffffb410}}
i = 2
mid = 2412
#7 0x00007fffdfd6c6ca in hex_mrb_command_eval (word=0x7fffffffb770, word_eol=0x7fffffffb660, mrb=0x136b6c0)
at mruby.c:1162
rb_word =
{value = {f = 1.040490392566165e-316, p = 0x14158b0, i = 21059760, sym = 21059760}, tt = MRB_TT_ARRAY}
rb_word_eol =
{value = {f = 1.0404809065057649e-316, p = 0x14157f0, i = 21059568, sym = 21059568}, tt = MRB_TT_ARRAY}
hexchat_module = 0x13b46e0
internal_class = 0x13b46b0
c = 0x11cb620
internal_class_v =
{value = {f = 1.0208352754170502e-316, p = 0x13b46b0, i = 20661936, sym = 20661936}, tt = MRB_TT_CLASS}
mid = 2412
cmd = 0x11fd574 "load"
#8 0x00000000004890c6 in plugin_hook_run (sess=0x770840, name=0x11fd570 "mrb", word=0x7fffffffb770, word_eol=0x7fffffffb660, attrs=0x0, type=1) at plugin.c:562
list =
0x1215b70 = {0x145a8a0, 0x1222a70, 0x1222a30, 0x128b070, 0x1317b40, 0x1237b10, 0x1334930, 0x1338660, 0x1370350, 0x132f4d0, 0x12aa780, 0x1299880, 0x12467c0, 0x121f9c0, 0x1299900, 0x12998c0, 0x7078b0, 0x12a9140, 0x12a9180, 0x137af70, 0x137afb0, 0x1468410, 0x14683b0, 0x1468350, 0x14682f0, 0x14682b0, 0x1468250, 0x1468210, 0x14681d0, 0x1468190, 0x1468150, 0x1468110, 0x1467e20, 0x1467de0}
next =
0x1215b00 = {0x1222a70, 0x1222a30, 0x128b070, 0x1317b40, 0x1237b10, 0x1334930, 0x1338660, 0x1370350, 0x132f4d0, 0x12aa780, 0x1299880, 0x12467c0, 0x121f9c0, 0x1299900, 0x12998c0, 0x7078b0, 0x12a9140, 0x12a9180, 0x137af70, 0x137afb0, 0x1468410, 0x14683b0, 0x1468350, 0x14682f0, 0x14682b0, 0x1468250, 0x1468210, 0x14681d0, 0x1468190, 0x1468150, 0x1468110, 0x1467e20, 0x1467de0}
hook = 0x145a8a0
ret = 32767
eat = 0
#9 0x0000000000489268 in plugin_emit_command (sess=0x770840, name=0x11fd570 "mrb", word=0x7fffffffb770, word_eol=0x7fffffffb660) at plugin.c:614
#10 0x000000000048808c in handle_command (sess=0x770840, cmd=0x1480301 "mrb load test/test.rb", check_spch=1)
at outbound.c:4696
pop = 0x7ffff5707d31 <g_strdup+49>
user_cmd = 0
list = Python Exception <class 'gdb.MemoryError'> Cannot access memory at address 0x742f747365742064:
#11 0x00000000004883af in handle_user_input (sess=0x770840, text=0x1480300 "/mrb load test/test.rb", history=1, nocommand=0) at outbound.c:4830
#12 0x0000000000488417 in handle_multiline (sess=0x770840, cmd=0x1480300 "/mrb load test/test.rb", history=1, nocommand=0) at outbound.c:4842
cr = 0x1480316 ""
end_of_string = 1
#13 0x000000000043bb9a in mg_inputbox_cb (igad=0x7891e0, gui=0x6dbac0 <static_mg_gui>) at maingui.c:341
cmd = 0x1480300 "/mrb load test/test.rb"
ignore = 0
list = Python Exception <class 'gdb.MemoryError'> Cannot access memory at address 0x2474ad158d481f:
Recursive reference eats all the stack, it doesn't play out well.
In mirb:
x = {}; x[x] = x; x[x]
/home/mg^/build/mruby-1.2.0/mrblib/array.rb:23: stack level too deep. (limit=(0x40000 - 128)) (SystemStackError)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.