Files
Waybar/include
Shivank Garg 38cc11c3b0 privacy: disconnect pending timeouts on destruction
The privacy module registers timeout callbacks in the GLib main context.
The GeoClue callback uses sigc::mem_fun() with the Privacy object, but the
connection remains active when the module is destroyed during a bar reload.

If the timeout runs after destruction, it dereferences the freed Privacy
object and crashes Waybar:

  #0 waybar::modules::privacy::Privacy::locationTimeout(bool)
  #4 g_main_context_iteration()
  #5 g_application_run()

Disconnect the GeoClue and visibility timeout connections in the Privacy
destructor so no callback can run after the module is gone.

The unpatched binary crashed after four SIGUSR2 reloads at 1.5-second
intervals. The patched binary survived ten reloads.

Fixes: eeb7bc702e ("Added GeoClue2 privacy item")
Assisted-by: Claude Opus + Cursor
2026-08-13 01:07:14 +05:30
..
2026-07-23 11:58:35 +03:00
2023-10-15 17:52:12 -03:00
2026-07-04 01:22:01 +02:00
2026-07-04 01:22:01 +02:00