st/icon-theme: Disconnect from settings signals on disposal
Icon themes can be created by extensions and thus are likely destroyed on extension unload, so we must disconnect from StSettings signals to avoid accessing to invalid memory. See: https://bugs.launchpad.net/ubuntu/+source/gnome-shell/+bug/2012021 Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2711>
This commit is contained in:
parent
95386a1423
commit
69e7b8e79a
@ -478,8 +478,8 @@ st_icon_theme_init (StIconTheme *icon_theme)
|
||||
icon_theme->pixbuf_supports_svg = pixbuf_supports_svg ();
|
||||
|
||||
settings = st_settings_get ();
|
||||
g_signal_connect (settings, "notify::gtk-icon-theme",
|
||||
G_CALLBACK (theme_changed), icon_theme);
|
||||
g_signal_connect_object (settings, "notify::gtk-icon-theme",
|
||||
G_CALLBACK (theme_changed), icon_theme, 0);
|
||||
update_current_theme (icon_theme);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user