From acaea79e7129ea2b3eb289a9ea3b2644ac970fba Mon Sep 17 00:00:00 2001 From: Ettore Perazzoli Date: Wed, 10 Oct 2001 14:10:51 +0000 Subject: Make this a no-op if the source and the destination path are the same. * e-storage.c (e_storage_async_xfer_folder): Make this a no-op if the source and the destination path are the same. * e-local-storage.c (impl_async_xfer_folder): return after returning `E_STORAGE_CANTCHANGESTOCKFOLDER' to the callback. * e-storage-set-view.c (handle_evolution_path_drag_motion): Make the check for dragging a folder over itself a little bit more accurate. svn path=/trunk/; revision=13550 --- shell/e-storage.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'shell/e-storage.c') diff --git a/shell/e-storage.c b/shell/e-storage.c index f482a0f6ce..0dc4d9a2f4 100644 --- a/shell/e-storage.c +++ b/shell/e-storage.c @@ -467,6 +467,11 @@ e_storage_async_xfer_folder (EStorage *storage, g_return_if_fail (destination_path != NULL); g_return_if_fail (g_path_is_absolute (destination_path)); + if (strcmp (source_path, destination_path) == 0) { + (* callback) (storage, E_STORAGE_OK, data); + return; + } + if (remove_source) { int destination_len; int source_len; -- cgit v1.2.3