History

checkpatch: improve parse_email signature checking

Bare email addresses with non alphanumeric characters require escape quoting before being substituted in the parse_email routine. e.g. Reported-by: syzbot+bbd8e9a06452cc48059b@syzkaller.appspotmail.com Do so.

Joe Perches committed 8 years ago

Commit 85e12061 parent 68c1f081 file · +1 −1Browse files

Showing the changes to scripts/checkpatch.pl (1 of 1 file). Show all

Unified · Split

scripts/checkpatch.pl+1−1
@@ -1075,7 +1075,7 @@ sub parse_email { · 1074 unmodified lines
1075 } elsif ($formatted_email =~ /(\S+\@\S+)(.*)$/) {1075 } elsif ($formatted_email =~ /(\S+\@\S+)(.*)$/) {
1076 $address = $1;1076 $address = $1;
1077 $comment = $2 if defined $2;1077 $comment = $2 if defined $2;
1078 $formatted_email =~ s/$address.*$//;1078 $formatted_email =~ s/\Q$address\E.*$//;
1079 $name = $formatted_email;1079 $name = $formatted_email;
1080 $name = trim($name);1080 $name = trim($name);
1081 $name =~ s/^\"|\"$//g;1081 $name =~ s/^\"|\"$//g;