aboutsummaryrefslogtreecommitdiffstats
path: root/mail
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2012-11-29 02:17:28 +0800
committerMilan Crha <mcrha@redhat.com>2012-11-29 02:17:28 +0800
commitaef0e1e7fd70373218cc395ddc74ac178ba9ca2f (patch)
tree90337be1a51070aa755a2aab929aefdef43a9557 /mail
parent8355f29a5d023ebfd75a146fd7f60a4035bcbba6 (diff)
downloadgsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar.gz
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar.bz2
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar.lz
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar.xz
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.tar.zst
gsoc2013-evolution-aef0e1e7fd70373218cc395ddc74ac178ba9ca2f.zip
Bug #672200 - Skip Reply-To-List check for list administrative messages
Diffstat (limited to 'mail')
-rw-r--r--mail/e-mail-reader.c26
1 files changed, 22 insertions, 4 deletions
diff --git a/mail/e-mail-reader.c b/mail/e-mail-reader.c
index ff3cf2d0fb..cc96053198 100644
--- a/mail/e-mail-reader.c
+++ b/mail/e-mail-reader.c
@@ -1429,6 +1429,21 @@ action_mail_reply_list_cb (GtkAction *action,
check_close_browser_reader (reader);
}
+static gboolean
+message_is_list_administrative (CamelMimeMessage *message)
+{
+ const gchar *header;
+
+ header = camel_medium_get_header ((CamelMedium *) message, "X-List-Administrivia");
+ if (!header)
+ return FALSE;
+
+ while (*header == ' ' || *header == '\t')
+ header++;
+
+ return g_ascii_strncasecmp (header, "yes", 3) == 0;
+}
+
static void
action_mail_reply_sender_check (CamelFolder *folder,
GAsyncResult *result,
@@ -1475,10 +1490,13 @@ action_mail_reply_sender_check (CamelFolder *folder,
munged_list_message = em_utils_is_munged_list_message (message);
- /* Don't do the "Are you sure you want to reply in private?" pop-up
- * if it's a Reply-To: munged list message... unless we're ignoring
- * munging. */
- if (ask_ignore_list_reply_to || !munged_list_message) {
+ if (message_is_list_administrative (message)) {
+ /* Do not ask for messages which are list administrative, like
+ list confirmation messages */
+ } else if (ask_ignore_list_reply_to || !munged_list_message) {
+ /* Don't do the "Are you sure you want to reply in private?" pop-up
+ * if it's a Reply-To: munged list message... unless we're ignoring
+ * munging. */
GtkWidget *dialog;
GtkWidget *check;
GtkWidget *container;