From: Joe Perches Date: Tue, 26 Jul 2011 00:13:26 +0000 (-0700) Subject: checkpatch: make utf-8 test --strict X-Git-Tag: v3.1-rc1~241^2~14 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=34d99219726ff4d3425b360d1e8d081627a73a00;p=platform%2Fupstream%2Fkernel-adaptation-pc.git checkpatch: make utf-8 test --strict Some patches are sent in using ISO-8859 or even Windows codepage 1252. Make checkpatch accept these by default and only emit the "Invalid UTF-8" message when using --strict. Signed-off-by: Joe Perches Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 05777ab..8dd720a 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -1609,8 +1609,8 @@ sub process { my $ptr = substr($blank, 0, length($utf8_prefix)) . "^"; my $hereptr = "$hereline$ptr\n"; - ERROR("INVALID_UTF8", - "Invalid UTF-8, patch and commit message should be encoded in UTF-8\n" . $hereptr); + CHK("INVALID_UTF8", + "Invalid UTF-8, patch and commit message should be encoded in UTF-8\n" . $hereptr); } # ignore non-hunk lines and lines being removed