Re: Mutt ignoring Reply-To
- To: mutt-dev@xxxxxxxx
- Subject: Re: Mutt ignoring Reply-To
- From: Jukka Salmi <j+mutt@xxxxxxxxxxxxx>
- Date: Thu, 2 Aug 2007 14:52:51 +0200
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/simple; d=salmi.ch; s=mx1; t=1186059171; bh=5SV5T3WE0ojAf+2PVhZqJMEJWKm1X921ILFGWGaMnDM=; h=X-DomainKeys:DomainKey-Signature:Received:Date:From:To:Subject: Message-ID:Mail-Followup-To:References:MIME-Version:Content-Type: Content-Disposition:In-Reply-To:X-Client-OS:User-Agent; b=k7sllAR3 MYvcThiIQQRXXgZB3o1ZTK6DOa6cI+V+q+WyrJKaYtJzlj9Vx08DERwrjhwbcjwMdMM h0ennrSiEuFxjOF4oFArNLNrDbi3Ph93/5zM2VYJ8YjvSUZjUcXFYtAfUYA8nqKixRH /E5HqEFOZftgsWE7+A9UoZ89wir42jcJEY70LA03CRvzDuqnLyiQTNDBB2TFw5OHLm6 97rJnAyOkHZQwq67oUk+1W11ESOAYwquyIbqO70HE82u1Zr6F3N4gDw/UNWErTFOZ1j 1Ie86tskr4yScCWnpiWnkvCBCWti1LyNGQHgbsh374Rwmn8tkfLlD5nmNKj3KYaW6w= =
- Domainkey-signature: a=rsa-sha1; s=mx1; d=salmi.ch; c=simple; q=dns; h=received:date:from:to:subject:message-id: mail-followup-to:references:mime-version:content-type: content-disposition:in-reply-to:x-client-os:user-agent; b=ylh/pOr5Rmr8bGShS06I9y4ncXIQo6NZ3qcqDGmp1dzKu0I4zI8GjrgD/LxCuTc/A HDrjvlv9zOrr8QSg7+hfoUJ7Y6fLZ2NEnxpMs0PSGkWhE+XTzYRH3IFLociPhHScVNm p5UAQQwdk7mbDKziMv5YzlmdXzleLe2JXe/WnujSoS26U7s9CXrVlMvR5AJPlsk7Xo8 yMrw5kELYMZTpqO8L+VzDJir5ufqHW2F4j690cbPi/B+K8o5/qsV+YPYPfdEmnX5NId TpmX7ncMo+dLaRgas5m6GvlkpVvFTUXWSV/fnt8qAeuhIkWrWOkUmHygWUPpMfYWsno VYUgGcrFg==
- In-reply-to: <20070802114113.GA19042@xxxxxxxxxxxxxx>
- List-post: <mailto:mutt-dev@mutt.org>
- List-unsubscribe: send mail to majordomo@mutt.org, body only "unsubscribe mutt-dev"
- Mail-followup-to: mutt-dev@xxxxxxxx
- References: <20070801095340.GA1341@xxxxxxxxxxxxxx> <20070801173448.GB22917@xxxxxxxxxxxxxxxxxxxxxxxxx> <20070802114113.GA19042@xxxxxxxxxxxxxx>
- Sender: owner-mutt-dev@xxxxxxxx
- User-agent: Mutt/1.5.16 (2007-07-16)
[moving from mutt-users]
Jukka Salmi --> mutt-users (2007-08-02 13:41:13 +0200):
> Rado S --> mutt-users (2007-08-01 19:34:48 +0200):
> > =- Jukka Salmi wrote on Wed 1.Aug'07 at 11:53:41 +0200 -=
> >
> > > I'm using Mutt 1.5.16. When replying to a mail which has a
> > > Reply-To header while reply_to is set, the address from the From
> > > header instead of the one from the Reply-To header ends up as the
> > > recipient address. I'd expect this behaviour only if reply_to is
> > > unset.
> >
> > Have a look at mutt-dev archives, reply-to behaviour has been
> > discussed there in more detail.
>
> Thanks for the hint. For the archives:
>
> http://dev.mutt.org/trac/ticket/2934
Hmm, glancing at the code, wouldn't the attached patch make everybody
happy?
Regards, Jukka
--
bashian roulette:
$ ((RANDOM%6)) || rm -rf ~
diff -r 6bc60516fffa send.c
--- a/send.c Wed Jul 25 11:16:49 2007 -0700
+++ b/send.c Thu Aug 02 14:38:28 2007 +0200
@@ -454,9 +454,9 @@ static int default_to (ADDRESS **to, ENV
if (flags & SENDLISTREPLY)
return 0;
- if (!option(OPTREPLYSELF) && mutt_addr_is_user (env->from))
- {
- /* mail is from the user, assume replying to recipients */
+ if (!option(OPTREPLYSELF) && mutt_addr_is_user (env->from) && !env->reply_to)
+ {
+ /* mail is from the user and Reply-To not set, assume replying to
recipients */
rfc822_append (to, env->to);
}
else if (env->reply_to)
@@ -496,7 +496,14 @@ static int default_to (ADDRESS **to, ENV
break;
case M_NO:
- rfc822_append (to, env->from);
+ if (!option(OPTREPLYSELF) && mutt_addr_is_user (env->from))
+ {
+ rfc822_append (to, env->to);
+ }
+ else
+ {
+ rfc822_append (to, env->from);
+ }
break;
default: