* check to prevent NULL-dereference (headers)
authorDirk-Jan C. Binnema <dirk-jan.binnema@nokia.com>
Mon, 5 Nov 2007 13:25:29 +0000 (13:25 +0000)
committerDirk-Jan C. Binnema <dirk-jan.binnema@nokia.com>
Mon, 5 Nov 2007 13:25:29 +0000 (13:25 +0000)
pmo-trunk-r3645

src/modest-ui-actions.c

index 8c9b693..7c581bd 100644 (file)
@@ -4257,6 +4257,11 @@ modest_ui_actions_xfer_messages_from_move_to (TnyFolderStore *dst_folder,
 
        /* Get selected headers */
        headers = get_selected_headers (MODEST_WINDOW (win));
+       if (!headers) {
+               g_warning ("%s: no headers selected", __FUNCTION__);
+               return;
+       }
+
 
        if (dst_is_pop) {
                modest_platform_information_banner (GTK_WIDGET (win),