diff options
-rw-r--r-- | libcaja-private/caja-desktop-link-monitor.c | 3 | ||||
-rw-r--r-- | libcaja-private/caja-desktop-link.c | 7 | ||||
-rw-r--r-- | src/caja-sidebar-title.c | 5 | ||||
-rw-r--r-- | src/caja-window-menus.c | 5 |
4 files changed, 15 insertions, 5 deletions
diff --git a/libcaja-private/caja-desktop-link-monitor.c b/libcaja-private/caja-desktop-link-monitor.c index 05cb7f4a..ee5d85d4 100644 --- a/libcaja-private/caja-desktop-link-monitor.c +++ b/libcaja-private/caja-desktop-link-monitor.c @@ -488,6 +488,7 @@ desktop_link_monitor_finalize (GObject *object) desktop_volumes_visible_changed, monitor); +/* These sources are already gone, this just causes errors if (monitor->details->mount_id != 0) { g_source_remove (monitor->details->mount_id); @@ -500,7 +501,7 @@ desktop_link_monitor_finalize (GObject *object) { g_source_remove (monitor->details->changed_id); } - +*/ g_free (monitor->details); EEL_CALL_PARENT (G_OBJECT_CLASS, finalize, (object)); diff --git a/libcaja-private/caja-desktop-link.c b/libcaja-private/caja-desktop-link.c index dfb1a54d..d695af6d 100644 --- a/libcaja-private/caja-desktop-link.c +++ b/libcaja-private/caja-desktop-link.c @@ -460,8 +460,11 @@ desktop_link_finalize (GObject *object) if (link->details->signal_handler != 0) { - g_signal_handler_disconnect (link->details->signal_handler_obj, - link->details->signal_handler); + if (g_signal_handler_is_connected(link->details->signal_handler_obj, + link->details->signal_handler)){ + g_signal_handler_disconnect (link->details->signal_handler_obj, + link->details->signal_handler); + } } if (link->details->icon_file != NULL) diff --git a/src/caja-sidebar-title.c b/src/caja-sidebar-title.c index 1cd8e14c..1f2c4295 100644 --- a/src/caja-sidebar-title.c +++ b/src/caja-sidebar-title.c @@ -212,8 +212,11 @@ release_file (CajaSidebarTitle *sidebar_title) { if (sidebar_title->details->file_changed_connection != 0) { - g_signal_handler_disconnect (sidebar_title->details->file, + if (g_signal_handler_is_connected(G_OBJECT (sidebar_title->details->file), + sidebar_title->details->file_changed_connection)){ + g_signal_handler_disconnect (sidebar_title->details->file, sidebar_title->details->file_changed_connection); + } sidebar_title->details->file_changed_connection = 0; } diff --git a/src/caja-window-menus.c b/src/caja-window-menus.c index d0fc2254..f6691876 100644 --- a/src/caja-window-menus.c +++ b/src/caja-window-menus.c @@ -98,8 +98,11 @@ bookmark_holder_new (CajaBookmark *bookmark, static void bookmark_holder_free (BookmarkHolder *bookmark_holder) { + if (g_signal_handler_is_connected(bookmark_holder->bookmark, + bookmark_holder->changed_handler_id)){ g_signal_handler_disconnect (bookmark_holder->bookmark, - bookmark_holder->changed_handler_id); + bookmark_holder->changed_handler_id); + } g_object_unref (bookmark_holder->bookmark); g_free (bookmark_holder); } |