[nautilus] application: don't unref unconditionally
- From: Cosimo Cecchi <cosimoc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [nautilus] application: don't unref unconditionally
- Date: Sat, 30 Oct 2010 15:22:40 +0000 (UTC)
commit e0f68583d47d23738afd7695f6137e2d2552b45d
Author: Cosimo Cecchi <cosimoc gnome org>
Date: Wed Oct 27 15:06:45 2010 +0200
application: don't unref unconditionally
As we're building the NautilusUndoManager in _startup() now, which might
not have been called if the application is remote.
src/nautilus-application.c | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
---
diff --git a/src/nautilus-application.c b/src/nautilus-application.c
index 2ae3732..ecc4424 100644
--- a/src/nautilus-application.c
+++ b/src/nautilus-application.c
@@ -1418,8 +1418,11 @@ nautilus_application_finalize (GObject *object)
application = NAUTILUS_APPLICATION (object);
nautilus_bookmarks_exiting ();
-
- g_object_unref (application->undo_manager);
+
+ if (application->undo_manager != NULL) {
+ g_object_unref (application->undo_manager);
+ application->undo_manager = NULL;
+ }
if (application->volume_monitor) {
g_object_unref (application->volume_monitor);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]