threads / patch / 11235

patchBrown paper bag fix to previous send-email change

Subject: [PATCH] Brown paper bag fix to previous send-email change

## tl;dr

5 messages between Dec 11, 2007 and Dec 11, 2007. Diffs are folded; open one to read it.

replies: 4people: 2as markdown or json

Mike Hommey· Dec 11, 2007, 06:55 UTC · lore

My previous change led to the In-Reply-To header being <> when the given value was empty. This fixes it.

Signed-off-by: Mike Hommey <mh@glandium.org>
---
 I think I have an antispam problem somewhere with this patch, because even
 keeping sending it, it never reached the list. And Junio didn't answer to my
 private message about it, so I guess that was some server being smart with
 the subject line. *sigh*
 PS: sorry Junio if you get this patch multiple time.
 git-send-email.perl |    6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)
Show changes to git-send-email.perl +4 −2
diff --git a/git-send-email.perl b/git-send-email.perl
index c0e1dd3..0e8c457 100755
--- a/git-send-email.perl
+++ b/git-send-email.perl
@@ -369,8 +369,10 @@ if ($thread && !defined $initial_reply_to && $prompting) {
 	$initial_reply_to = $_;
 }
 
-$initial_reply_to =~ s/^\s*<?/</;
-$initial_reply_to =~ s/>?\s*$/>/;
+if ($initial_reply_to) {
+	$initial_reply_to =~ s/^\s*<?/</;
+	$initial_reply_to =~ s/>?\s*$/>/;
+}
 
 if (!defined $smtp_server) {
 	foreach (qw( /usr/sbin/sendmail /usr/lib/sendmail )) {
-- 
1.5.3.7.1161.g14b8
Junio C Hamano· Dec 11, 2007, 07:04 UTC · re: Mike Hommey · lore

Re: [PATCH] Brown paper bag fix to previous send-email change

Mike Hommey <mh@glandium.org> writes:
Show 12 quoted lines
> My previous change led to the In-Reply-To header being <> when the given
> value was empty. This fixes it.
>
> Signed-off-by: Mike Hommey <mh@glandium.org>
> ---
>
>  I think I have an antispam problem somewhere with this patch, because even
>  keeping sending it, it never reached the list. And Junio didn't answer to my
>  private message about it, so I guess that was some server being smart with
>  the subject line. *sigh*
>
>  PS: sorry Junio if you get this patch multiple time.

No, I happened to have noticed the same and have an almost identical fix (I said "defined $initial_reply_to") already queued in my tree.

Mike Hommey· Dec 11, 2007, 07:44 UTC · re: Junio C Hamano · lore

Re: [PATCH] Brown paper bag fix to previous send-email change

On Mon, Dec 10, 2007 at 11:04:36PM -0800, Junio C Hamano wrote:
Show 17 quoted lines
> Mike Hommey <mh@glandium.org> writes:
> 
> > My previous change led to the In-Reply-To header being <> when the given
> > value was empty. This fixes it.
> >
> > Signed-off-by: Mike Hommey <mh@glandium.org>
> > ---
> >
> >  I think I have an antispam problem somewhere with this patch, because even
> >  keeping sending it, it never reached the list. And Junio didn't answer to my
> >  private message about it, so I guess that was some server being smart with
> >  the subject line. *sigh*
> >
> >  PS: sorry Junio if you get this patch multiple time.
> 
> No, I happened to have noticed the same and have an almost identical fix
> (I said "defined $initial_reply_to") already queued in my tree.

Testing "defined $initial_reply_to" might not be enough, because $initial_reply_to can be defined and empty.

Mike
Junio C Hamano· Dec 11, 2007, 08:02 UTC · re: Mike Hommey · lore

Re: [PATCH] Brown paper bag fix to previous send-email change

Mike Hommey <mh@glandium.org> writes:
Show 21 quoted lines
> On Mon, Dec 10, 2007 at 11:04:36PM -0800, Junio C Hamano wrote:
>> Mike Hommey <mh@glandium.org> writes:
>> 
>> > My previous change led to the In-Reply-To header being <> when the given
>> > value was empty. This fixes it.
>> >
>> > Signed-off-by: Mike Hommey <mh@glandium.org>
>> > ---
>> >
>> >  I think I have an antispam problem somewhere with this patch, because even
>> >  keeping sending it, it never reached the list. And Junio didn't answer to my
>> >  private message about it, so I guess that was some server being smart with
>> >  the subject line. *sigh*
>> >
>> >  PS: sorry Junio if you get this patch multiple time.
>> 
>> No, I happened to have noticed the same and have an almost identical fix
>> (I said "defined $initial_reply_to") already queued in my tree.
>
> Testing "defined $initial_reply_to" might not be enough, because $initial_reply_to
> can be defined and empty.

And if empty what does your regexp do? Produce "<>"? How's that useful?

Junio C Hamano· Dec 11, 2007, 08:06 UTC · re: Mike Hommey · lore

Re: [PATCH] Brown paper bag fix to previous send-email change

Mike Hommey <mh@glandium.org> writes:
Show 5 quoted lines
>> No, I happened to have noticed the same and have an almost identical fix
>> (I said "defined $initial_reply_to") already queued in my tree.
>
> Testing "defined $initial_reply_to" might not be enough, because $initial_reply_to
> can be defined and empty.
Ah, I see what you mean.  Thanks.

← back to recent threads