Skip to content

Commit

Permalink
get_maintainer: quote email address with period
Browse files Browse the repository at this point in the history
Picky mail systems won't accept email addresses where recipient has period
in name; ie.  David S.  Miller <davemloft.net> will not work.

Signed-off-by: Stephen Hemminger <[email protected]>
Acked-by: Joe Perches <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Stephen Hemminger authored and torvalds committed Mar 6, 2010
1 parent 22dd5b0 commit a63ceb4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/get_maintainer.pl
Original file line number Diff line number Diff line change
Expand Up @@ -605,7 +605,7 @@ sub parse_email {
$name =~ s/^\"|\"$//g;
$address =~ s/^\s+|\s+$//g;

if ($name =~ /[^a-z0-9 \.\-]/i) { ##has "must quote" chars
if ($name =~ /[^\w \-]/i) { ##has "must quote" chars
$name =~ s/(?<!\\)"/\\"/g; ##escape quotes
$name = "\"$name\"";
}
Expand All @@ -622,7 +622,7 @@ sub format_email {
$name =~ s/^\"|\"$//g;
$address =~ s/^\s+|\s+$//g;

if ($name =~ /[^a-z0-9 \.\-]/i) { ##has "must quote" chars
if ($name =~ /[^\w \-]/i) { ##has "must quote" chars
$name =~ s/(?<!\\)"/\\"/g; ##escape quotes
$name = "\"$name\"";
}
Expand Down

0 comments on commit a63ceb4

Please sign in to comment.