Re: Failure to extra stable@xxxxxxxxxxxxxxx addresses

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Nov 20, 2012 at 8:56 AM, Krzysztof Mazur <krzysiek@xxxxxxxxxxxx> wrote:

> --- a/git-send-email.perl
> +++ b/git-send-email.perl
> @@ -925,8 +925,11 @@ sub quote_subject {
>  sub sanitize_address {
>         my ($recipient) = @_;
>
> +       my $local_part_regexp = qr/[^<>"\s@]+/;
> +       my $domain_regexp = qr/[^.<>"\s@]+(?:\.[^.<>"\s@]+)+/;
> +
>         # remove garbage after email address
> -       $recipient =~ s/(.*>).*$/$1/;
> +       $recipient =~ s/^(.*?<$local_part_regexp\@$domain_regexp>).*/$1/;

I don't think all that extra complexity is warranted, to me
s/(.*?>)(.*)$/$1/ is just fine.

Cheers.

-- 
Felipe Contreras
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]