* Fixes NB#90762, initialize and free a private field
authorSergio Villar Senin <svillar@igalia.com>
Thu, 23 Oct 2008 17:01:11 +0000 (17:01 +0000)
committerSergio Villar Senin <svillar@igalia.com>
Thu, 23 Oct 2008 17:01:11 +0000 (17:01 +0000)
pmo-trunk-r6151

src/widgets/modest-window-mgr.c

index 5ee28b9..6da29ad 100644 (file)
@@ -217,6 +217,8 @@ modest_window_mgr_init (ModestWindowMgr *obj)
 
        priv->cached_view = NULL;
        priv->cached_editor = NULL;
+
+       priv->windows_that_prevent_hibernation = NULL;
 }
 
 static void
@@ -243,6 +245,11 @@ modest_window_mgr_finalize (GObject *obj)
                priv->cached_editor = NULL;
        }
 
+       if (priv->windows_that_prevent_hibernation) {
+               g_slist_free (priv->windows_that_prevent_hibernation);
+               priv->cached_editor = NULL;
+       }
+
        g_slist_foreach (priv->preregistered_uids, (GFunc)g_free, NULL);
        g_slist_free (priv->preregistered_uids);