2005-05-05 [paul] 1.9.6cvs54
authorPaul Mangan <paul@claws-mail.org>
Thu, 5 May 2005 11:38:49 +0000 (11:38 +0000)
committerPaul Mangan <paul@claws-mail.org>
Thu, 5 May 2005 11:38:49 +0000 (11:38 +0000)
sync with HEAD

* AUTHORS
* src/compose.c
fix bug 713 'Resent-To and Resent-Cc headers are garbled'
patch by Tim Mann

AUTHORS
ChangeLog-gtk2.claws
PATCHSETS
configure.ac
src/compose.c

diff --git a/AUTHORS b/AUTHORS
index 8476769..6c48d69 100644 (file)
--- a/AUTHORS
+++ b/AUTHORS
@@ -223,3 +223,4 @@ contributors (beside the above; based on Changelog)
        Ivan Rayner
        Markus Schwarzenberg
        Luca Cavalli
+       Tim Mann
index f5259a3..90d7396 100644 (file)
@@ -1,3 +1,12 @@
+2005-05-05 [paul]      1.9.6cvs54
+       
+       sync with HEAD
+
+       * AUTHORS
+       * src/compose.c
+               fix bug 713 'Resent-To and Resent-Cc headers are garbled'
+               patch by Tim Mann
+
 2005-05-05 [paul]      1.9.6cvs53
 
        * src/mainwindow.c
index 66e4ae5..3b81aee 100644 (file)
--- a/PATCHSETS
+++ b/PATCHSETS
 ( cvs diff -u -r 1.36.2.28 -r 1.36.2.29 src/common/utils.c; ) > 1.9.6cvs51.patchset
 ( cvs diff -u -r 1.61.2.23 -r 1.61.2.24 src/account.c; cvs diff -u -r 1.5.10.8 -r 1.5.10.9 src/addrgather.c; cvs diff -u -r 1.2.4.6 -r 1.2.4.7 src/browseldap.c; cvs diff -u -r 1.3.2.8 -r 1.3.2.9 src/exphtmldlg.c; cvs diff -u -r 1.1.4.10 -r 1.1.4.11 src/expldifdlg.c; cvs diff -u -r 1.4.12.5 -r 1.4.12.6 src/importmutt.c; cvs diff -u -r 1.1.14.5 -r 1.1.14.6 src/importpine.c; cvs diff -u -r 1.115.2.31 -r 1.115.2.32 src/main.c; cvs diff -u -r 1.274.2.35 -r 1.274.2.36 src/mainwindow.c; cvs diff -u -r 1.5.2.6 -r 1.5.2.7 src/noticeview.c; cvs diff -u -r 1.59.2.16 -r 1.59.2.17 src/prefs_filtering.c; cvs diff -u -r 1.1.4.12 -r 1.1.4.13 src/prefs_filtering_action.c; cvs diff -u -r 1.43.2.17 -r 1.43.2.18 src/prefs_matcher.c; cvs diff -u -r 1.5.2.6 -r 1.5.2.7 src/prefs_spelling.c; cvs diff -u -r 1.30.2.11 -r 1.30.2.12 src/prefs_toolbar.c; cvs diff -u -r 1.43.2.15 -r 1.43.2.16 src/toolbar.c; cvs diff -u -r 1.1.2.7 -r 1.1.2.8 src/wizard.c; cvs diff -u -r 1.5.2.8 -r 1.5.2.9 src/gtk/description_window.c; cvs diff -u -r 1.5.2.2 -r 1.5.2.3 src/gtk/gtkvscrollbutton.c; cvs diff -u -r 1.1.4.8 -r 1.1.4.9 src/gtk/progressdialog.c; cvs diff -u -r 1.1.2.17 -r 1.1.2.18 src/gtk/quicksearch.c; cvs diff -u -r 1.1.2.6 -r 1.1.2.7 src/plugins/pgpmime/prefs_gpg.c; cvs diff -u -r 1.23.2.8 -r 1.23.2.9 src/plugins/spamassassin/spamassassin_gtk.c; ) > 1.9.6cvs52.patchset
 ( cvs diff -u -r 1.274.2.36 -r 1.274.2.37 src/mainwindow.c; ) > 1.9.6cvs53.patchset
+( cvs diff -u -r 1.100.2.16 -r 1.100.2.17 AUTHORS; cvs diff -u -r 1.382.2.119 -r 1.382.2.120 src/compose.c; ) > 1.9.6cvs54.patchset
index 7029f7c..223d5da 100644 (file)
@@ -11,7 +11,7 @@ MINOR_VERSION=9
 MICRO_VERSION=6
 INTERFACE_AGE=0
 BINARY_AGE=0
-EXTRA_VERSION=53
+EXTRA_VERSION=54
 EXTRA_RELEASE=
 EXTRA_GTK2_VERSION=
 
index 38ea185..08aace8 100644 (file)
@@ -3239,13 +3239,11 @@ static gint compose_redirect_write_headers_from_headerlist(Compose *compose,
        to_hdr = prefs_common.trans_hdr ? _("To:") : "To:";
 
        first_to_address = TRUE;
-       first_cc_address = TRUE;
        for (list = compose->header_list; list; list = list->next) {
                headerentry = ((ComposeHeaderEntry *)list->data);
                headerentryname = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(headerentry->combo)->entry));
 
-               if (g_utf8_collate(headerentryname, cc_hdr) == 0 
-                  || g_utf8_collate(headerentryname, to_hdr) == 0) {
+               if (g_utf8_collate(headerentryname, to_hdr) == 0) {
                        const gchar *entstr = gtk_entry_get_text(GTK_ENTRY(headerentry->entry));
                        Xstrdup_a(str, entstr, return -1);
                        g_strstrip(str);
@@ -3253,32 +3251,49 @@ static gint compose_redirect_write_headers_from_headerlist(Compose *compose,
                                compose_convert_header
                                        (buf, sizeof(buf), str,
                                        strlen("Resent-To") + 2, TRUE);
-                               if (g_utf8_collate(headerentryname, to_hdr) == 0) {
-                                       if (first_to_address) {
-                                               fprintf(fp, "Resent-To: ");
-                                               first_to_address = FALSE;
-                                       } else {
-                                               fprintf(fp, ",");
-                                       }
-                               }
-                               if (g_utf8_collate(headerentryname, cc_hdr) == 0) {
-                                       if (first_cc_address) {
-                                               fprintf(fp, "\n");
-                                               fprintf(fp, "Resent-Cc: ");
-                                               first_cc_address = FALSE;
-                                       } else {
-                                               fprintf(fp, ",");
-                                       }
-                               }
-                               
+
+                               if (first_to_address) {
+                                       fprintf(fp, "Resent-To: ");
+                                       first_to_address = FALSE;
+                               } else {
+                                       fprintf(fp, ",");
+                                }
                                fprintf(fp, "%s", buf);
                        }
                }
        }
-       /* if (!first_address) { */
-       fprintf(fp, "\n");
-       /* } */
+       if (!first_to_address) {
+               fprintf(fp, "\n");
+       }
 
+       first_cc_address = TRUE;
+       for (list = compose->header_list; list; list = list->next) {
+               headerentry = ((ComposeHeaderEntry *)list->data);
+               headerentryname = gtk_entry_get_text(GTK_ENTRY(GTK_COMBO(headerentry->combo)->entry));
+
+               if (g_utf8_collate(headerentryname, cc_hdr) == 0) {
+                       const gchar *strg = gtk_entry_get_text(GTK_ENTRY(headerentry->entry));
+                       Xstrdup_a(str, strg, return -1);
+                       g_strstrip(str);
+                       if (str[0] != '\0') {
+                               compose_convert_header
+                                       (buf, sizeof(buf), str,
+                                       strlen("Resent-Cc") + 2, TRUE);
+
+                                if (first_cc_address) {
+                                        fprintf(fp, "Resent-Cc: ");
+                                        first_cc_address = FALSE;
+                                } else {
+                                        fprintf(fp, ",");
+                                }
+                               fprintf(fp, "%s", buf);
+                       }
+               }
+       }
+       if (!first_cc_address) {
+               fprintf(fp, "\n");
+        }
+       
        return(0);
 }