[PATCH] scripts/checkpatch.pl: Warn on non-executable files created with non 100644 file permissions

[PATCH] scripts/checkpatch.pl: Warn on non-executable files created with non 100644 file permissions

Post by Rabin Vinc » Fri, 08 Oct 2010 19:50:02



> + > my $mode = $1;
> + gt;my $file = $2;
> + if ($mode ne "100644">&& !($file =~ /\.(sh|pl|py|awk)$/)) {
> + WARN("FILE '$file' should probably >se file permissio> 100644 not $>ode\n" . $herecurr);
> + }
> + }
> +

There's a vaguely similar patch already in -mm. That one also handles mode
changes and doesn't require the presence of the diff summary. Have a look in
case you missed it, maybe it does most of what you want and you can base
something on that:

http://www.yqcomputer.com/ ~akpm/mmotm/broken-out/checkpatch-check-for-incorrect-permissions.patch
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to XXXX@XXXXX.COM
More majordomo info at http://www.yqcomputer.com/
Please read the FAQ at http://www.yqcomputer.com/