diff options
author | Dan Winship <danw@src.gnome.org> | 2000-06-13 02:55:20 +0800 |
---|---|---|
committer | Dan Winship <danw@src.gnome.org> | 2000-06-13 02:55:20 +0800 |
commit | 0931d27d61aa9f0ccc579be8d4c7b3c56bdd684f (patch) | |
tree | 0faf3c795f2e413e0243c04f0e12a6d814aab449 | |
parent | 870e780ce28ddf39ea25009878201464f4c5a8ea (diff) | |
download | gsoc2013-evolution-0931d27d61aa9f0ccc579be8d4c7b3c56bdd684f.tar.gz gsoc2013-evolution-0931d27d61aa9f0ccc579be8d4c7b3c56bdd684f.tar.zst gsoc2013-evolution-0931d27d61aa9f0ccc579be8d4c7b3c56bdd684f.zip |
Fix the subject generation so we don't get "Re: Re:". This is working
* mail-format.c (mail_generate_reply): Fix the subject generation
so we don't get "Re: Re:". This is working around something that
may later be declared a misfeature in Camel.
svn path=/trunk/; revision=3531
-rw-r--r-- | mail/ChangeLog | 6 | ||||
-rw-r--r-- | mail/mail-format.c | 13 |
2 files changed, 15 insertions, 4 deletions
diff --git a/mail/ChangeLog b/mail/ChangeLog index e5a7cac760..1ffb588b60 100644 --- a/mail/ChangeLog +++ b/mail/ChangeLog @@ -1,3 +1,9 @@ +2000-06-12 Dan Winship <danw@helixcode.com> + + * mail-format.c (mail_generate_reply): Fix the subject generation + so we don't get "Re: Re:". This is working around something that + may later be declared a misfeature in Camel. + 2000-06-10 Ettore Perazzoli <ettore@helixcode.com> * component-factory.c (create_folder): New stub implementation for diff --git a/mail/mail-format.c b/mail/mail-format.c index 729fa5f42a..5612b0a55b 100644 --- a/mail/mail-format.c +++ b/mail/mail-format.c @@ -1393,10 +1393,15 @@ mail_generate_reply (CamelMimeMessage *message, gboolean to_all) subject = (char *)camel_mime_message_get_subject (message); if (!subject) subject = g_strdup (""); - else if (!strncasecmp (subject, "Re: ", 4)) - subject = g_strdup (subject); - else - subject = g_strdup_printf ("Re: %s", subject); + else { + while (*subject == ' ') + subject++; + + if (!strncasecmp (subject, "Re: ", 4)) + subject = g_strdup (subject); + else + subject = g_strdup_printf ("Re: %s", subject); + } e_msg_composer_set_headers (composer, to, cc, NULL, subject); g_list_free (to); |