From 0fcee08809330b47fd56bc8c82e118fa5663a5ec Mon Sep 17 00:00:00 2001 From: Venkata Narendra Kumar Gutta Date: Mon, 6 May 2019 15:44:44 -0700 Subject: [PATCH] checkpatch: Fix the commit log false positive warnings Checkpatch is throwing a warning for lines that contains file delta in the commit log. WARNING: Possible unwrapped commit description (prefer a maximum 75 chars per line) kerneldir/msm-abc-xyz123.dtsi | 68 ++++++++++++++++++++++++++++++++++++++++---- This file delta line of the patch should be ignored for maximum characters per line check and is taken care of already, but it's not covering if the file has '-' in its name. Update the conditional check to cover this case. Change-Id: If37691aa897f8a991c1643a08fbde45cc4afaaf7 Signed-off-by: Venkata Narendra Kumar Gutta --- scripts/checkpatch.pl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 0249b153651b..79851c968779 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -2838,7 +2838,7 @@ sub process { # Check for line lengths > 75 in commit log, warn once if ($in_commit_log && !$commit_log_long_line && length($line) > 75 && - !($line =~ /^\s*[a-zA-Z0-9_\/\.]+\s+\|\s+\d+/ || + !($line =~ /^\s*[a-zA-Z0-9_\/\.\-]+\s+\|\s+\d+/ || # file delta changes $line =~ /^\s*(?:[\w\.\-]+\/)++[\w\.\-]+:/ || # filename then :