From 7ab4ccfe7670d38a00fa2a9c06dcc7a60a4c2726 Mon Sep 17 00:00:00 2001 From: Not Zed Date: Fri, 16 Jan 2004 07:14:15 +0000 Subject: change this to check the store using the provider url_cmp and just lookup 2004-01-16 Not Zed * mail-folder-cache.c (storeinfo_find_folder_info): change this to check the store using the provider url_cmp and just lookup the folder name directly. folder_compare can't be used for uri's, this stuff was so broken, my fault :( ** See bug #52467. * em-folder-tree-model.c (sort_cb): handle null path (root?). * mail-vfolder.c (mail_vfolder_add_uri): map uri to euri before processing. (rule_changed): map uri to camel uri before looking up. (mail_vfolder_delete_uri): handle as euri internally. (mail_vfolder_rename_uri): " * mail-autofilter.c (vfolder_rule_from_message): map camel uri to euri before setting as vfolder source. svn path=/trunk/; revision=24266 --- mail/em-folder-tree-model.c | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) (limited to 'mail/em-folder-tree-model.c') diff --git a/mail/em-folder-tree-model.c b/mail/em-folder-tree-model.c index 6f409cfb05..fc29c5e761 100644 --- a/mail/em-folder-tree-model.c +++ b/mail/em-folder-tree-model.c @@ -214,12 +214,20 @@ sort_cb (GtkTreeModel *model, GtkTreeIter *a, GtkTreeIter *b, gpointer user_data return -1; path = gtk_tree_model_get_path (model, a); - aname = gtk_tree_path_to_string (path); - gtk_tree_path_free (path); + if (path) { + aname = gtk_tree_path_to_string (path); + gtk_tree_path_free (path); + } else { + aname = g_strdup(""); + } path = gtk_tree_model_get_path (model, b); - bname = gtk_tree_path_to_string (path); - gtk_tree_path_free (path); + if (path) { + bname = gtk_tree_path_to_string (path); + gtk_tree_path_free (path); + } else { + bname = g_strdup(""); + } ret = strcmp (aname, bname); g_free (aname); -- cgit