Dear Maintainer,
on trixie, gnome-shell (48.7-0+deb13u2, Wayland) repeatedly crashed with
SIGSEGV about one second after login. The coredump shows the crash inside
libxkbregistry, called from libxml2's error reporting while libgweather
parses a weather response:
#0 n/a (libxkbregistry.so.0 + 0x25ff)
#1 n/a (libxkbregistry.so.0 + 0x28a2)
#2 n/a (libxml2.so.2 + 0x36c0e)
#3 __xmlRaiseError (libxml2.so.2 + 0x3873d)
...
#8 xmlParseElement (libxml2.so.2)
#9 xmlParseDocument (libxml2.so.2)
#10 xmlParseMemory (libxml2.so.2)
#11 n/a (libgweather-4.so.0 + 0x1d932)
#12-#28 libgio / libsoup-3.0 callbacks
#31 g_main_loop_run
#32 meta_context_run_main_loop (libmutter-16.so.0)
This is upstream issue
https://github.com/xkbcommon/libxkbcommon/issues/529
rxkb_context_parse() installs a global libxml2 error handler that refers
to the rxkb_context and does not reset it. Once the context is freed, any
later libxml2 parse error in the same process (here: libgweather) crashes.
Upstream fixed it in libxkbcommon 1.8.0 (NEWS: "Registry: Fixed libxml2
global error handler not reset after parsing, which could trigger a crash
if the corresponding rxkb_context has been freed."). trixie-backports has
1.13.1, but trixie itself still ships 1.7.0-2.
Whether the crash happens depends on the weather service response, so it
appears random to users. Workaround: remove the weather location in
GNOME Shell (gsettings set org.gnome.shell.weather locations "[]").
Could the upstream fix be backported to trixie via a stable update?
Other versions involved:
libxml2 2.12.7+dfsg+really2.9.14-2.1+deb13u3
libgweather-4-0t64 4.4.4-1
libsoup-3.0-0 3.6.5-3
libmutter-16-0 48.7-0+deb13u1
Thanks!