diff options
Diffstat (limited to 'src/ui/accounts.c')
-rw-r--r-- | src/ui/accounts.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/ui/accounts.c b/src/ui/accounts.c index 969c23d..84e932e 100644 --- a/src/ui/accounts.c +++ b/src/ui/accounts.c | |||
@@ -95,11 +95,11 @@ handle_dialog_destroy(UNUSED GtkWidget *window, | |||
95 | { | 95 | { |
96 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; | 96 | MESSENGER_Application *app = (MESSENGER_Application*) user_data; |
97 | 97 | ||
98 | ui_accounts_dialog_cleanup(&(app->ui.accounts)); | 98 | if ((app->ui.accounts.show_queued) || |
99 | (gtk_widget_is_visible(GTK_WIDGET(app->ui.messenger.main_window)))) | ||
100 | return; | ||
99 | 101 | ||
100 | if ((!(app->ui.accounts.show_queued)) && | 102 | gtk_widget_destroy(GTK_WIDGET(app->ui.messenger.main_window)); |
101 | (!gtk_widget_is_visible(GTK_WIDGET(app->ui.messenger.main_window)))) | ||
102 | gtk_widget_destroy(GTK_WIDGET(app->ui.messenger.main_window)); | ||
103 | } | 103 | } |
104 | 104 | ||
105 | static int | 105 | static int |
@@ -219,5 +219,5 @@ ui_accounts_dialog_cleanup(UI_ACCOUNTS_Handle *handle) | |||
219 | { | 219 | { |
220 | g_object_unref(handle->builder); | 220 | g_object_unref(handle->builder); |
221 | 221 | ||
222 | handle->accounts_listbox = NULL; | 222 | memset(handle, 0, sizeof(*handle)); |
223 | } | 223 | } |