Segfault with latest rfb patch + qemu CVS
Hi there,
Am trying to get the latest rfb8 patch working with the latest CVS qemu (from libvncserver.sf.net/qemu) but not having a lot of luck. I made one modification to vnc.c which took out the reference to the SDL display driver which I didn't want to compile in.
The crash looks like this:
antec:/home/mattbee/builds/qemu# gdb ./i386-softmmu/qemu (gdb) set args -vnc -k en-gb ../../hda (gdb) run Starting program: /home/mattbee/builds/qemu/i386-softmmu/qemu -vnc -k en-gb ../../hda [Thread debugging using libthread_db enabled] [New Thread 1075684928 (LWP 19768)] Connected to host network interface: tun0 Detaching after fork from child process 19772.
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1075684928 (LWP 19768)] 0x40118844 in strcmp () from /lib/tls/libc.so.6 (gdb) bt
#0 0x40118844 in strcmp () from /lib/tls/libc.so.6 #1 0xffffffff in ?? () #2 0x0807dc93 in get_keysym (name=0xbfffc860 "Shift_R")
at keyboard_rdesktop.c:20
#3 0x0807de93 in parse_keyboard_layout (language=0xbfffc867 "", k=0x8f6ba40)
at keyboard_rdesktop.c:81
#4 0x0807dfa6 in parse_keyboard_layout (language=0xbfffcca8 "modifiers\n",
k=0x8f6ba40) at keyboard_rdesktop.c:73
#5 0x0807dfa6 in parse_keyboard_layout (language=0xbfffd0e8 "common\n",
k=0x8f6ba40) at keyboard_rdesktop.c:73
#6 0x0807e025 in init_keyboard_layout (language=0x0)
at keyboard_rdesktop.c:118
#7 0x0807ef82 in vnc_display_init (ds=0x80f6880, useAlsoSDL=0)
at /home/mattbee/builds/qemu/vnc.c:472
#8 0x0804ef6b in main (argc=5, argv=0xbfffda04)
at /home/mattbee/builds/qemu/vl.c:3319Any pointers appreciated at this early stage :)
Matthew
Hi,
Quoted 4 lines · Matthew Bloch
Am trying to get the latest rfb8 patch working with the latest CVS qemu (from libvncserver.sf.net/qemu) but not having a lot of luck. I made one modification to
vnc.cwhich took out the reference to the SDL display driver which I didn't want to compile in.
And it doesn't work without your change, too?
Quoted 7 lines
Starting program:
/home/mattbee/builds/qemu/i386-softmmu/qemu-vnc -k en-gb ../../hda
[Thread debugging usinglibthread_dbenabled]
[New Thread 1075684928 (LWP 19768)]
Connected to host network interface: tun0
Detaching after fork from child process 19772.
Quoted 8 lines
Program received signal SIGSEGV, Segmentation fault. [Switching to Thread 1075684928 (LWP 19768)]
0x40118844in strcmp () from/lib/tls/libc.so.6(gdb) bt#0 0x40118844 in strcmp () from /lib/tls/libc.so.6 #1 0xffffffff in ?? () #2 0x0807dc93 in get_keysym (name=0xbfffc860 "Shift_R")at keyboard_rdesktop.c:20
Strange. The STRCMP in my version is on line 13, not 20. Are you sure you haven't made more changes? Anyway, this is a binary search through all keysyms. The only way there can be a SIGSEGV is that the indexes go out of bounds. Or your keysym_adapter_vnc.h is fscked. It should be a very long array of struct name2keysym_t.
Hth,
Dscho