when using qemu with sdl under wayland(Ubuntu 22.04) a Segmentation fault raised, don't know where it's comes from.
(gdb) bt
#0 0x00007ffff78fccb6 in () at /lib/x86_64-linux-gnu/libSDL2-2.0.so.0
#1 0x00007ffff48bd8e6 in () at /lib/x86_64-linux-gnu/libffi.so.8
#2 0x00007ffff48ba426 in () at /lib/x86_64-linux-gnu/libffi.so.8
#3 0x00007ffff49c406b in wl_closure_invoke
(closure=0x55555acad2a0, flags=1, target=0x555556d85c90, opcode=1, data=0x555556d85d20)
at ../../src/connection.c:1025
#4 0x00007ffff49c0efc in dispatch_event (display=0x555557af1980, queue=0x555557af1a50)
at ../../src/wayland-client.c:1583
#5 0x00007ffff49c11f2 in dispatch_queue (display=0x555557af1980, queue=0x555557af1a50)
at ../../src/wayland-client.c:1729
#6 0x00007ffff49c14dd in wl_display_dispatch_queue_pending (display=0x555557af1980, queue=0x555557af1a50)
at ../../src/wayland-client.c:1971
#7 0x00007ffff49c14a2 in wl_display_dispatch_queue (display=0x555557af1980, queue=0x555557af1a50)
at ../../src/wayland-client.c:1947
#8 0x00007ffff49c1521 in wl_display_dispatch (display=0x555557af1980) at ../../src/wayland-client.c:2014
#9 0x00007ffff78fb53f in () at /lib/x86_64-linux-gnu/libSDL2-2.0.so.0
#10 0x00007ffff7843970 in () at /lib/x86_64-linux-gnu/libSDL2-2.0.so.0
#11 0x00007ffff78439bd in () at /lib/x86_64-linux-gnu/libSDL2-2.0.so.0
#12 0x0000555555aac9c8 in sdl2_poll_events (scon=0x555557114688) at ../../ui/sdl2.c:643
#13 0x000055555586f79a in dpy_refresh (s=<optimized out>, s=0x55555794fb20) at ../../ui/console.c:1753
#14 gui_update (opaque=opaque@entry=0x55555794fb20) at ../../ui/console.c:163
#15 0x0000555555e237c9 in timerlist_run_timers (timer_list=0x555556725830) at ../../util/qemu-timer.c:573
#16 0x0000555555e23a09 in timerlist_run_timers (timer_list=<optimized out>) at ../../util/qemu-timer.c:506
#17 qemu_clock_run_timers (type=<optimized out>) at ../../util/qemu-timer.c:587
#18 qemu_clock_run_all_timers () at ../../util/qemu-timer.c:669
#19 0x0000555555e1f443 in main_loop_wait (nonblocking=nonblocking@entry=0) at ../../util/main-loop.c:542
#20 0x00005555558add3b in qemu_main_loop () at ../../softmmu/runstate.c:727
#21 0x0000555555861202 in main (argc=<optimized out>, argv=<optimized out>, envp=<optimized out>)
at ../../softmmu/main.c:50
Edited by Yonggang Luo