MLMMJ Mailing List Manager
 help / color / mirror / Atom feed
From: Christian Laursen <xi@borderworlds.dk>
To: mlmmj@mlmmj.org
Subject: Re: Two To: headers added to auto-mails from list
Date: Tue, 04 Apr 2006 18:16:55 +0000	[thread overview]
Message-ID: <868xqlp5ns.fsf@borg.borderworlds.dk> (raw)
In-Reply-To: <44312C59.8000100@925.dk>

[-- Attachment #1: Type: text/plain, Size: 888 bytes --]

Martin Koch Andersen <martin@925.dk> writes:

> I have noticed that in emails from the list (confirm-sub, sub-ok etc.)
> I get two To: headers.
>
> In the configuration of my list I have 'Add To: header'. And in
> Delete headers' 'To:' is listed also.

I have just reproduced this.

> Why do I get this extra To: header? Could it be a bug with the
> mentioned configuration above?

The problem is that when addtohdr is true, an extra To: header is
always appended by mlmmj-send even for mails not going to the list
subscribers, e.g. subscribe confirmations and mails to moderators.

I have made a small patch that only sets addtohdr from the control
dir when resending earlier failed mails or sending normal list mail.
I am however not sure that this is the right solution, so I would
welcome any input.

The patch is attached.

> Using latest version.

I know. :)

-- 
Christian Laursen

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: mlmmj-send.c patch --]
[-- Type: text/x-patch, Size: 831 bytes --]

diff -urN mlmmj-1.2.11.orig/src/mlmmj-send.c mlmmj-1.2.11/src/mlmmj-send.c
--- mlmmj-1.2.11.orig/src/mlmmj-send.c	Tue Nov  1 14:23:49 2005
+++ mlmmj-1.2.11/src/mlmmj-send.c	Tue Apr  4 19:43:42 2006
@@ -823,7 +823,6 @@
 		exit(EXIT_FAILURE);
 	}
 
-	addtohdr = statctrl(listdir, "addtohdr");
 	memmailsizestr = ctrlvalue(listdir, "memorymailsize");
 	ctrlarchive = statctrl(listdir, "noarchive");
 	if(memmailsizestr) {
@@ -886,6 +885,7 @@
 		}
 		break;
 	case '3':
+		addtohdr = statctrl(listdir, "addtohdr");
 	case '4': /* sending mails to subfile */
 		if((subfd = open(subfilename, O_RDONLY)) < 0) {
 			log_error(LOG_ARGS, "Could not open '%s':",
@@ -904,6 +904,7 @@
 						archivefilename);
 		break;
 	default: /* normal list mail -- now handled when forking */
+		addtohdr = statctrl(listdir, "addtohdr");
 		break;
 	}
 

  parent reply	other threads:[~2006-04-04 18:16 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-03 14:08 Two To: headers added to auto-mails from list Martin Koch Andersen
2006-04-03 21:21 ` Morten K. Poulsen
2006-04-04 16:31 ` Martin Koch Andersen
2006-04-04 18:16 ` Christian Laursen [this message]
2006-04-04 22:37 ` Morten K. Poulsen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=868xqlp5ns.fsf@borg.borderworlds.dk \
    --to=xi@borderworlds.dk \
    --cc=mlmmj@mlmmj.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox