Log creating and destroying of queue for debugging
authorSeunghun Lee <shiin.lee@samsung.com>
Thu, 10 Nov 2022 09:58:52 +0000 (18:58 +0900)
committerJunkyeong Kim <jk0430.kim@samsung.com>
Thu, 16 Feb 2023 10:22:44 +0000 (19:22 +0900)
commitc925321214d12a04c1284a51e7be17c1a4341bfc
tree21510da098e8e1d0edc0f8f7756bdd68ec843ea1
parent501bd5afdbd47bfcd7ea0975c2bfea2f277eeb24
Log creating and destroying of queue for debugging

Crashes has been observed several times in libwayland-client.so with the
following backtrace.

 #0 0x44ff4b56 in wl_list_insert (list=0xb1c03678, elm=elm@entry=0x207c1f8) at /usr/src/debug/wayland-1.20.0/builddir/../src/wayland-util.c:60
 #1 0x44ff6de0 in queue_event (len=8, display=<optimized out>) at /usr/src/debug/wayland-1.20.0/builddir/../src/wayland-client.c:1940
 #2 read_events (display=0x20733b0) at /usr/src/debug/wayland-1.20.0/builddir/../src/wayland-client.c:2184
 #3 wl_display_read_events (display=0x20733b0) at /usr/src/debug/wayland-1.20.0/builddir/../src/wayland-client.c:2380
 ...

I've tried to investigate it and I suppose there is high possibility
that somewhere using libwayland-client could destroy a wl_event_queue
first before all wayland proxies that the queue is associated with.

So, this patch adds log message in where creating and destroying a queue
in the hope that it would help us find the cause of problem next time.

Change-Id: If6a35ec738c2cf88b9ef7dea46bcd1b2fb4821ba
src/wayland-client.c