diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2001-07-06 01:41:53 +0800 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2001-07-06 01:41:53 +0800 |
commit | 6c2482302fdf8e90b7bbd85a534075d4bbea40a2 (patch) | |
tree | 037375ceffa35bb38db24038d572eb65713af2b1 | |
parent | bcf19b2ae70dc58802147c88652b46039e7e7101 (diff) | |
download | gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar.gz gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar.bz2 gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar.lz gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar.xz gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.tar.zst gsoc2013-evolution-6c2482302fdf8e90b7bbd85a534075d4bbea40a2.zip |
if source == dest, just no-op.
2001-07-05 Jeffrey Stedfast <fejj@ximian.com>
* camel-folder.c (camel_folder_copy_messages_to): if source ==
dest, just no-op.
svn path=/trunk/; revision=10817
-rw-r--r-- | camel/ChangeLog | 5 | ||||
-rw-r--r-- | camel/camel-folder.c | 7 |
2 files changed, 11 insertions, 1 deletions
diff --git a/camel/ChangeLog b/camel/ChangeLog index 1a94bd7942..a55a98b336 100644 --- a/camel/ChangeLog +++ b/camel/ChangeLog @@ -1,3 +1,8 @@ +2001-07-05 Jeffrey Stedfast <fejj@ximian.com> + + * camel-folder.c (camel_folder_copy_messages_to): if source == + dest, just no-op. + 2001-07-05 Peter Williams <peterw@ximian.com> * camel-vee-folder.c (camel_vee_folder_finalise): Move this before the diff --git a/camel/camel-folder.c b/camel/camel-folder.c index 4e679f36ae..2326fb6300 100644 --- a/camel/camel-folder.c +++ b/camel/camel-folder.c @@ -1092,7 +1092,7 @@ copy_message_to (CamelFolder *source, const char *uid, CamelFolder *dest, CamelE { CamelMimeMessage *msg; CamelMessageInfo *info = NULL; - + /* Default implementation. */ /* we alredy have the lock, dont deadlock */ @@ -1147,6 +1147,11 @@ camel_folder_copy_messages_to (CamelFolder *source, GPtrArray *uids, g_return_if_fail (CAMEL_IS_FOLDER (dest)); g_return_if_fail (uids != NULL); + if (source == dest) { + /* source and destination folders are the same, do nothing. */ + return; + } + CAMEL_FOLDER_LOCK(source, lock); if (source->parent_store == dest->parent_store) |