2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-25 13:43:55 +08:00
linux-next/drivers/staging/cx25821
Joe Perches 95cd17c9f3 staging: Remove unnecessary semicolons when switch (foo) {...};
Done via perl script:

$ cat remove_semi_switch.pl
my $match_balanced_parentheses = qr/(\((?:[^\(\)]++|(?-1))*\))/;
my $match_balanced_braces      = qr/(\{(?:[^\{\}]++|(?-1))*\})/;

foreach my $file (@ARGV) {
    my $f;
    my $text;
    my $oldtext;

    next if ((-d $file));

    open($f, '<', $file)
	or die "$P: Can't open $file for read\n";
    $oldtext = do { local($/) ; <$f> };
    close($f);

    next if ($oldtext eq "");

    $text = $oldtext;

    my $count = 0;
    do {
	$count = 0;
	$count += $text =~ s@\b(switch\s*${match_balanced_parentheses}\s*)${match_balanced_braces}\s*;@"$1$3"@egx;
    } while ($count > 0);

    if ($text ne $oldtext) {
	my $newfile = $file;

	open($f, '>', $newfile)
	    or die "$P: Can't open $newfile for write\n";
	print $f $text;
	close($f);
    }
}

$

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2011-04-25 16:58:35 -07:00
..
cx25821-alsa.c [media] staging/cx25721: serialize access to devlist 2011-03-21 20:32:41 -03:00
cx25821-audio-upstream.c staging: cx25821: Remove NULL check before kfree 2011-03-14 11:57:31 -07:00
cx25821-audio-upstream.h [media] Staging: cx25821: remove spaces after parenthesis 2010-10-21 01:17:07 -02:00
cx25821-audio.h Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6 2010-10-28 12:13:00 -07:00
cx25821-biffuncs.h V4L/DVB (12733): cx25821: some CodingStyle fixes 2009-09-18 23:47:38 -03:00
cx25821-cards.c [media] drivers/staging/cx25821: Use pr_fmt and pr_<level> 2010-12-29 08:16:46 -02:00
cx25821-core.c [media] staging/cx25721: serialize access to devlist 2011-03-21 20:32:41 -03:00
cx25821-gpio.c V4L/DVB: cx25821: fix coding style issues in cx25821-gpio.c 2010-05-18 00:51:14 -03:00
cx25821-gpio.h V4L/DVB (12733): cx25821: some CodingStyle fixes 2009-09-18 23:47:38 -03:00
cx25821-i2c.c [media] drivers/staging/cx25821: Use pr_fmt and pr_<level> 2010-12-29 08:16:46 -02:00
cx25821-medusa-defines.h V4L/DVB: cx25821: Removed duplicate code and cleaned up 2010-08-02 15:18:44 -03:00
cx25821-medusa-reg.h [media] Staging: cx25821: fix braces and space coding style issues 2010-10-21 01:17:08 -02:00
cx25821-medusa-video.c [media] drivers/staging/cx25821: Use pr_fmt and pr_<level> 2010-12-29 08:16:46 -02:00
cx25821-medusa-video.h V4L/DVB: cx25821: Removed duplicate code and cleaned up 2010-08-02 15:18:44 -03:00
cx25821-reg.h [media] Staging: cx25821: fix braces and space coding style issues 2010-10-21 01:17:08 -02:00
cx25821-sram.h V4L/DVB: cx25821: Make comments C99 compliant 2010-08-02 15:18:48 -03:00
cx25821-video-upstream-ch2.c staging: cx25821: Remove NULL check before kfree 2011-03-14 11:57:31 -07:00
cx25821-video-upstream-ch2.h [media] Staging: cx25821: fix braces and space coding style issues 2010-10-21 01:17:08 -02:00
cx25821-video-upstream.c staging: cx25821: Remove NULL check before kfree 2011-03-14 11:57:31 -07:00
cx25821-video-upstream.h [media] Staging: cx25821: fix braces and space coding style issues 2010-10-21 01:17:08 -02:00
cx25821-video.c staging: Remove unnecessary semicolons when switch (foo) {...}; 2011-04-25 16:58:35 -07:00
cx25821-video.h [media] V4L: remove V4L1 compatibility mode 2010-12-29 08:17:07 -02:00
cx25821.h [media] staging/cx25721: serialize access to devlist 2011-03-21 20:32:41 -03:00
Kconfig [media] staging/cx25721: serialize access to devlist 2011-03-21 20:32:41 -03:00
Makefile Staging: cx25821: Makefile: replace the use of <module>-objs with <module>-y 2010-10-08 07:23:51 -07:00
README V4L/DVB (12847): cx25821: Add README with todo list 2009-09-19 00:13:32 -03:00

Todo:
	- checkpatch.pl cleanups
	- sparse cleanups

Please send patches to linux-media@vger.kernel.org