[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <d6451fbddb3a17c7bad1c2d574e86e00e7295258.camel@perches.com>
Date: Mon, 16 Aug 2021 04:42:26 -0700
From: Joe Perches <joe@...ches.com>
To: Mimi Zohar <zohar@...ux.ibm.com>
Cc: Andy Whitcroft <apw@...onical.com>,
Dwaipayan Ray <dwaipayanray1@...il.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Simon Thoby <simon.thoby@...eris.fr>,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] checkpatch: make email address check case insensitive
On Mon, 2021-08-16 at 07:27 -0400, Mimi Zohar wrote:
> Instead of checkpatch requiring the patch author to exactly match the
> signed-off-by tag, commit 48ca2d8ac8a1 ("checkpatch: add new warnings
> to author signoff checks.") safely relaxed this requirement.
>
> Although the local-part of an email address (local-part@...ain), may
> be case sensitive, exploiting the case sensitivity of mailbox
> local-parts impedes interoperability and is discouraged. Mailbox
> domains follow normal DNS rules and are hence not case sensitive.
> (Refer to https://datatracker.ietf.org/doc/html/rfc5321#section-2.4.)
>
> Further relax the patch author and signed-off-by tag comparison by
> making the email address check case insensitive.
>
> Signed-off-by: Mimi Zohar <zohar@...ux.ibm.com>
Acked-by: Joe Perches <joe@...ches.com>
> ---
> scripts/checkpatch.pl | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> index 461d4221e4a4..1efa2997df62 100755
> --- a/scripts/checkpatch.pl
> +++ b/scripts/checkpatch.pl
> @@ -2909,10 +2909,10 @@ sub process {
> my ($email_name, $email_comment, $email_address, $comment1) = parse_email($ctx);
> my ($author_name, $author_comment, $author_address, $comment2) = parse_email($author);
>
>
> - if ($email_address eq $author_address && $email_name eq $author_name) {
> + if (lc $email_address eq lc $author_address && $email_name eq $author_name) {
> $author_sob = $ctx;
> $authorsignoff = 2;
> - } elsif ($email_address eq $author_address) {
> + } elsif (lc $email_address eq lc $author_address) {
> $author_sob = $ctx;
> $authorsignoff = 3;
> } elsif ($email_name eq $author_name) {
Powered by blists - more mailing lists