2006-05-29 [paul] 2.2.0cvs63
authorPaul Mangan <paul@claws-mail.org>
Mon, 29 May 2006 09:00:26 +0000 (09:00 +0000)
committerPaul Mangan <paul@claws-mail.org>
Mon, 29 May 2006 09:00:26 +0000 (09:00 +0000)
* src/mh.c
fetch full message when moving mails
from another mailbox, (fixed data loss
when filtering from IMAP to MH, introduced
in 2.2.0cvs57).
Thanks to Colin

ChangeLog
PATCHSETS
configure.ac
src/mh.c

index 253dc5d..ca540c8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+2006-05-29 [paul]      2.2.0cvs63
+
+       * src/mh.c
+               fetch full message when moving mails
+               from another mailbox, (fixed data loss
+               when filtering from IMAP to MH, introduced
+               in 2.2.0cvs57).
+               Thanks to Colin
+
 2006-05-29 [mones]     2.2.0cvs62
 
        * src/gtk/gtksctree.c
index 8c2757d..a845aaa 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.26.2.25 -r 1.26.2.26 src/foldersel.c;  ) > 2.2.0cvs60.patchset
 ( cvs diff -u -r 1.395.2.210 -r 1.395.2.211 src/summaryview.c;  ) > 2.2.0cvs61.patchset
 ( cvs diff -u -r 1.1.4.19 -r 1.1.4.20 src/gtk/gtksctree.c;  ) > 2.2.0cvs62.patchset
+( cvs diff -u -r 1.79.2.32 -r 1.79.2.33 src/mh.c;  ) > 2.2.0cvs63.patchset
index ac7c067..5316473 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=2
 MICRO_VERSION=0
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=62
+EXTRA_VERSION=63
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 85e89ae..7035cca 100644 (file)
--- a/src/mh.c
+++ b/src/mh.c
@@ -465,6 +465,7 @@ static gint mh_copy_msgs(Folder *folder, FolderItem *dest, MsgInfoList *msglist,
        MsgInfoList *cur = NULL;
        gint curnum = 0, total = 0;
        gchar *srcpath = NULL;
+       gboolean full_fetch = FALSE;
 
        g_return_val_if_fail(dest != NULL, -1);
        g_return_val_if_fail(msglist != NULL, -1);
@@ -478,6 +479,9 @@ static gint mh_copy_msgs(Folder *folder, FolderItem *dest, MsgInfoList *msglist,
                return -1;
        }
 
+       if (msginfo->folder->folder != dest->folder)
+               full_fetch = TRUE;
+
        if (dest->last_num < 0) {
                mh_get_last_num(folder, dest);
                if (dest->last_num < 0) return -1;
@@ -513,7 +517,13 @@ static gint mh_copy_msgs(Folder *folder, FolderItem *dest, MsgInfoList *msglist,
                if (!msginfo) {
                        goto err_reset_status;
                }
-               srcfile = g_strconcat(srcpath, G_DIR_SEPARATOR_S, itos(msginfo->msgnum), NULL);
+               if (!full_fetch) {
+                       srcfile = g_strconcat(srcpath, 
+                               G_DIR_SEPARATOR_S, 
+                               itos(msginfo->msgnum), NULL);
+               } else {
+                       srcfile = procmsg_get_message_file(msginfo);
+               }
                if (!srcfile) {
                        goto err_reset_status;
                }