From 8f23df2f04a765292d4d6ab77c9814c9c922cf3e Mon Sep 17 00:00:00 2001 From: Milan Crha Date: Thu, 3 Jul 2008 14:28:19 +0000 Subject: ** Fix for bug #541365 2008-07-03 Milan Crha ** Fix for bug #541365 * message-list.c: (message_list_get_uids), (message_list_get_selected): Do not call 'camel_folder_sort_uids' when we do not have folder or uid. svn path=/trunk/; revision=35719 --- mail/message-list.c | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'mail/message-list.c') diff --git a/mail/message-list.c b/mail/message-list.c index 756974c832..cdd9fad99d 100644 --- a/mail/message-list.c +++ b/mail/message-list.c @@ -3440,8 +3440,10 @@ message_list_get_uids(MessageList *ml) }; e_tree_path_foreach(ml->tree, ml_getselected_cb, &data); - camel_folder_sort_uids (ml->folder, data.uids); - + + if (ml->folder && data.uids->len) + camel_folder_sort_uids (ml->folder, data.uids); + return data.uids; } @@ -3454,8 +3456,10 @@ message_list_get_selected(MessageList *ml) }; e_tree_selected_path_foreach(ml->tree, ml_getselected_cb, &data); - camel_folder_sort_uids (ml->folder, data.uids); - + + if (ml->folder && data.uids->len) + camel_folder_sort_uids (ml->folder, data.uids); + return data.uids; } -- cgit