瀏覽代碼

get_maintainer: repair STDIN usage

Commit 22dd5b0cba50a197aaa3bd2790a29ee2e8e4e372 (fix perlcritic warnings)
broke the ability to handle STDIN because the three argument version of
open() cannot handle standard IO-streams (which is mentioned in
PerlBestPractices, too).

Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Cc: Stephen Hemminger <shemminger@vyatta.com>
Acked-by: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Wolfram Sang 15 年之前
父節點
當前提交
3a4df13d24
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      scripts/get_maintainer.pl

+ 1 - 1
scripts/get_maintainer.pl

@@ -284,7 +284,7 @@ foreach my $file (@ARGV) {
 	my $file_cnt = @files;
 	my $file_cnt = @files;
 	my $lastfile;
 	my $lastfile;
 
 
-	open(my $patch, '<', $file)
+	open(my $patch, "< $file")
 	    or die "$P: Can't open $file: $!\n";
 	    or die "$P: Can't open $file: $!\n";
 	while (<$patch>) {
 	while (<$patch>) {
 	    my $patch_line = $_;
 	    my $patch_line = $_;