Saving state causes segfault in xnp21kai
Opened this issue · 3 comments
DestyNova commented
I checked out the latest version (commit 2b09ea6) and installed sdlnp21kai and xnp21kai.
xnp21kai works, but exits with a segfault when I try to make a savestate (either from the "Stat" or "Debug" menus).
Here's the backtrace captured by gdb:
Thread 1 "xnp21kai" received signal SIGSEGV, Segmentation fault.
0x0000000000000000 in ?? ()
(gdb) bt
#0 0x0000000000000000 in ()
#1 0x00005555555f1854 in flagsave_com (tbl=<optimized out>, tbl=0x555555751de0 <np2tbl+1312>, sfh=0x5555571627d0) at /home/omf/emu/pc98/NP2kai/statsave.c:1416
#2 statsave_save_d () at /home/omf/emu/pc98/NP2kai/statsave.c:1594
#3 0x000055555569fdb5 in mainloop (p=<optimized out>) at /home/omf/emu/pc98/NP2kai/x/np2.c:351
#4 0x00007ffff7eb9c24 in g_main_context_dispatch () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#5 0x00007ffff7f0e6f8 in () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#6 0x00007ffff7eb9293 in g_main_loop_run () at /lib/x86_64-linux-gnu/libglib-2.0.so.0
#7 0x00007ffff79dc2d2 in gtk_main () at /lib/x86_64-linux-gnu/libgtk-x11-2.0.so.0
#8 0x00005555556b93d3 in gui_gtk_widget_mainloop () at /home/omf/emu/pc98/NP2kai/x/gtk2/gtk_main.c:337
#9 0x0000555555587330 in main (argc=<optimized out>, argv=<optimized out>) at /home/omf/emu/pc98/NP2kai/x/main.c:441
sdlnp21kai works, but can't upscale the screen so it's too hard to see what's happening on my laptop...
DestyNova commented
The line that seems to cause the segfault in statsave.c is this:
flag = (COMFLAG)cm->msg(cm, COMMSG_GETFLAG, 0);
The device it's trying to save flags for is cm_rs232c
, which is non-null.
eadmaster commented
same here an Android libretro.
zk395 commented
I can confirm this is still an issue.