Skip to content

client: Disconnect all signal handlers when client is disposed

I've encountered an intermittent GNOME Shell crash when needrestart is allowed to restart system services that are using outdated shared libraries, which sometimes includes BlueZ. The crash seems to involve signals being delivered to a freed BluetoothClient, which can be avoided by using g_signal_connect_object(). I haven't encountered the crash since applying this change, although since it was always intermittent I cannot be sure that it is fully solved.

This might be caused by using the Bluetooth Quick Connect shell extension, which will create and destroy a BluetoothClient when the extension is loaded and unloaded, which will in turn happen when the screen is locked (due to extensions being disabled in the lock screen).

Bug-Debian: https://bugs.debian.org/932405

Edited by Simon McVittie

Merge request reports