Fixed a situation in which we could notify the shell listener twice.
2003-01-10 Jeffrey Stedfast <fejj@ximian.com> * component-factory.c (storage_remove_folder): Fixed a situation in which we could notify the shell listener twice. svn path=/trunk/; revision=19401
This commit is contained in:

committed by
Jeffrey Stedfast

parent
5a20da25d3
commit
b71068d4e3
@ -1,3 +1,8 @@
|
|||||||
|
2003-01-10 Jeffrey Stedfast <fejj@ximian.com>
|
||||||
|
|
||||||
|
* component-factory.c (storage_remove_folder): Fixed a situation
|
||||||
|
in which we could notify the shell listener twice.
|
||||||
|
|
||||||
2003-01-10 Not Zed <NotZed@Ximian.com>
|
2003-01-10 Not Zed <NotZed@Ximian.com>
|
||||||
|
|
||||||
* folder-browser.c (folder_browser_gui_init): Save the paned_size
|
* folder-browser.c (folder_browser_gui_init): Save the paned_size
|
||||||
|
@ -1261,8 +1261,11 @@ storage_remove_folder (EvolutionStorage *storage,
|
|||||||
root = camel_store_get_folder_info (store, name, CAMEL_STORE_FOLDER_INFO_FAST |
|
root = camel_store_get_folder_info (store, name, CAMEL_STORE_FOLDER_INFO_FAST |
|
||||||
CAMEL_STORE_FOLDER_INFO_RECURSIVE, &ex);
|
CAMEL_STORE_FOLDER_INFO_RECURSIVE, &ex);
|
||||||
camel_url_free (url);
|
camel_url_free (url);
|
||||||
if (!root || camel_exception_is_set (&ex))
|
if (!root || camel_exception_is_set (&ex)) {
|
||||||
goto exception;
|
notify_listener_exception (listener, &ex);
|
||||||
|
camel_exception_clear (&ex);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
/* walk the tree until we find the particular child folder we want to delete */
|
/* walk the tree until we find the particular child folder we want to delete */
|
||||||
fi = root;
|
fi = root;
|
||||||
@ -1272,23 +1275,20 @@ storage_remove_folder (EvolutionStorage *storage,
|
|||||||
fi = fi->child;
|
fi = fi->child;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (fi != NULL) {
|
if (!fi) {
|
||||||
storage_remove_folder_recursive (storage, store, fi, &ex);
|
|
||||||
if (camel_exception_is_set (&ex))
|
|
||||||
goto exception;
|
|
||||||
} else {
|
|
||||||
notify_listener (listener, GNOME_Evolution_Storage_INVALID_URI);
|
notify_listener (listener, GNOME_Evolution_Storage_INVALID_URI);
|
||||||
|
camel_store_free_folder_info (store, root);
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
storage_remove_folder_recursive (storage, store, fi, &ex);
|
||||||
camel_store_free_folder_info (store, root);
|
camel_store_free_folder_info (store, root);
|
||||||
|
if (camel_exception_is_set (&ex)) {
|
||||||
notify_listener (listener, GNOME_Evolution_Storage_OK);
|
notify_listener_exception (listener, &ex);
|
||||||
return;
|
camel_exception_clear (&ex);
|
||||||
|
} else {
|
||||||
exception:
|
notify_listener (listener, GNOME_Evolution_Storage_OK);
|
||||||
notify_listener_exception(listener, &ex);
|
}
|
||||||
camel_exception_clear (&ex);
|
|
||||||
camel_store_free_folder_info (store, root);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -532,13 +532,13 @@ account_to_xml (MailConfigAccount *account)
|
|||||||
|
|
||||||
xmlDocDumpMemory (doc, &xmlbuf, &n);
|
xmlDocDumpMemory (doc, &xmlbuf, &n);
|
||||||
xmlFreeDoc (doc);
|
xmlFreeDoc (doc);
|
||||||
|
|
||||||
/* remap to glib memory */
|
/* remap to glib memory */
|
||||||
tmp = g_malloc(n+1);
|
tmp = g_malloc (n + 1);
|
||||||
memcpy(tmp, xmlbuf, n);
|
memcpy (tmp, xmlbuf, n);
|
||||||
tmp[n] = 0;
|
tmp[n] = '\0';
|
||||||
xmlFree(xmlbuf);
|
xmlFree (xmlbuf);
|
||||||
|
|
||||||
return tmp;
|
return tmp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user