lkml.org 
[lkml]   [2013]   [Mar]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH] checkpatch: do not exit in main process subroutine
From
Date
On Sat, 2013-03-30 at 18:30 +0800, zhangwei(Jovi) wrote:
> On 2013/3/28 11:43, zhangwei(Jovi) wrote:
> > Currently checkpatch program exit when process empty file,
> > This will cause issue when @ARGV include many files ready to check.
[]
> > diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
> > @@ -3634,19 +3634,19 @@ sub process {
> > # If we have no input at all, then there is nothing to report on
> > # so just keep quiet.
> > if ($#rawlines == -1) {
> > - exit(0);
> > + return $clean;
> > }

I think instead this should be something like adding

if (!is_patch && $#rawlines == -1) {
return $clean;
}

though maybe expecting checkpatch to avoid empty files
when fed a directory list is unrealistic.




\
 
 \ /
  Last update: 2013-04-01 06:41    [W:0.080 / U:0.304 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site