aboutsummaryrefslogtreecommitdiffstats
path: root/mail/message-list.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2000-08-04 12:04:11 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2000-08-04 12:04:11 +0800
commit61fae09dc0157bde0e1853a788c200e6830978a7 (patch)
tree4924edc3eb0c75342596ee85bd7817e07bc796ab /mail/message-list.c
parent623b1de43d610df7dc767153aed62ec7e40894a6 (diff)
downloadgsoc2013-evolution-61fae09dc0157bde0e1853a788c200e6830978a7.tar.gz
gsoc2013-evolution-61fae09dc0157bde0e1853a788c200e6830978a7.tar.zst
gsoc2013-evolution-61fae09dc0157bde0e1853a788c200e6830978a7.zip
Fix a possible crash when using the quicksearch by freeing the UID
array correctly. svn path=/trunk/; revision=4525
Diffstat (limited to 'mail/message-list.c')
-rw-r--r--mail/message-list.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/mail/message-list.c b/mail/message-list.c
index f2565866d4..91a177ffc4 100644
--- a/mail/message-list.c
+++ b/mail/message-list.c
@@ -850,10 +850,14 @@ message_list_regenerate (MessageList *message_list, const char *search)
build_flat (message_list, message_list->tree_root, uids);
if (search) {
- g_strfreev ((char **)uids->pdata);
- g_ptr_array_free (uids, FALSE);
- } else
+ int i;
+
+ for (i = 0; i < uids->len; i++)
+ g_free (g_ptr_array_index (uids, i));
+ g_ptr_array_free (uids, TRUE);
+ } else {
camel_folder_free_uids (message_list->folder, uids);
+ }
e_table_model_changed (message_list->table_model);
select_msg (message_list, 0);