aboutsummaryrefslogtreecommitdiffstats
path: root/modules/mail
diff options
context:
space:
mode:
Diffstat (limited to 'modules/mail')
-rw-r--r--modules/mail/e-mail-shell-view-private.c11
-rw-r--r--modules/mail/e-mail-shell-view-private.h6
2 files changed, 5 insertions, 12 deletions
diff --git a/modules/mail/e-mail-shell-view-private.c b/modules/mail/e-mail-shell-view-private.c
index cb37b6e374..cf917f5251 100644
--- a/modules/mail/e-mail-shell-view-private.c
+++ b/modules/mail/e-mail-shell-view-private.c
@@ -855,17 +855,16 @@ e_mail_shell_view_private_dispose (EMailShellView *mail_shell_view)
priv->prepare_for_quit_handler_id = 0;
}
- DISPOSE (priv->mail_shell_backend);
- DISPOSE (priv->mail_shell_content);
- DISPOSE (priv->mail_shell_sidebar);
+ g_clear_object (&priv->mail_shell_backend);
+ g_clear_object (&priv->mail_shell_content);
+ g_clear_object (&priv->mail_shell_sidebar);
for (ii = 0; ii < MAIL_NUM_SEARCH_RULES; ii++)
- DISPOSE (priv->search_rules[ii]);
+ g_clear_object (&priv->search_rules[ii]);
if (priv->opening_folder != NULL) {
g_cancellable_cancel (priv->opening_folder);
- g_object_unref (priv->opening_folder);
- priv->opening_folder = NULL;
+ g_clear_object (&priv->opening_folder);
}
if (priv->search_account_all != NULL) {
diff --git a/modules/mail/e-mail-shell-view-private.h b/modules/mail/e-mail-shell-view-private.h
index bd9db02b10..28d90d463b 100644
--- a/modules/mail/e-mail-shell-view-private.h
+++ b/modules/mail/e-mail-shell-view-private.h
@@ -70,12 +70,6 @@
#define ACTION_GROUP(name) \
(E_SHELL_WINDOW_ACTION_GROUP_##name (shell_window))
-/* For use in dispose() methods. */
-#define DISPOSE(obj) \
- G_STMT_START { \
- if ((obj) != NULL) { g_object_unref (obj); (obj) = NULL; } \
- } G_STMT_END
-
/* ETable Specifications */
#define ETSPEC_FILENAME "message-list.etspec"