From 398d45654eaaefd1a20631a343192f68a6025dcd Mon Sep 17 00:00:00 2001 From: Jose Dapena Paz Date: Tue, 10 Jul 2007 07:06:00 +0000 Subject: [PATCH 1/1] * src/maemo/modest-platform.c: * Fixed a crash that happened on moving messages to outbox. The code to connect and wait, didn't consider the case of a message from a folder without an account (fixes NB#62872). pmo-trunk-r2661 --- src/maemo/modest-platform.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/maemo/modest-platform.c b/src/maemo/modest-platform.c index 685d6fc..5812b27 100644 --- a/src/maemo/modest-platform.c +++ b/src/maemo/modest-platform.c @@ -1047,8 +1047,10 @@ gboolean modest_platform_connect_and_wait_if_network_folderstore (GtkWindow *par if (TNY_IS_FOLDER (folder_store)) { /* Get the folder's parent account: */ TnyAccount *account = tny_folder_get_account(TNY_FOLDER (folder_store)); - result = modest_platform_connect_and_wait_if_network_account (NULL, account); - g_object_unref (account); + if (account != NULL) { + result = modest_platform_connect_and_wait_if_network_account (NULL, account); + g_object_unref (account); + } } else if (TNY_IS_ACCOUNT (folder_store)) { /* Use the folder store as an account: */ result = modest_platform_connect_and_wait_if_network_account (NULL, TNY_ACCOUNT (folder_store)); -- 1.7.9.5