Bugzilla – Attachment 58533 Details for
Bug 17447
Remove unused vars from batchRebuildItemsTables.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 17447: %opt is unused
Bug-17447-opt-is-unused.patch (text/plain), 1.13 KB, created by
Mark Tompsett
on 2016-12-30 15:45:28 UTC
(
hide
)
Description:
Bug 17447: %opt is unused
Filename:
MIME Type:
Creator:
Mark Tompsett
Created:
2016-12-30 15:45:28 UTC
Size:
1.13 KB
patch
obsolete
>From e1d0ed5b52bb69f4f504c5ac706122eaf2ee82c7 Mon Sep 17 00:00:00 2001 >From: Mark Tompsett <mtompset@hotmail.com> >Date: Fri, 30 Dec 2016 10:12:24 -0500 >Subject: [PATCH] Bug 17447: %opt is unused > >Deleted the line. >perlcritic -4 before and after. >Before there are issues. After there is not. > >Also, changed function to not rely on implicit return value >of last line, but explicitly stated a return. And operator >changed, due to precedence issues. > >Signed-off-by: Mark Tompsett <mtompset@hotmail.com> >--- > misc/batchRebuildItemsTables.pl | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > >diff --git a/misc/batchRebuildItemsTables.pl b/misc/batchRebuildItemsTables.pl >index a18e321..9e38757 100755 >--- a/misc/batchRebuildItemsTables.pl >+++ b/misc/batchRebuildItemsTables.pl >@@ -34,7 +34,6 @@ my $count = 0; > my $errorcount = 0; > my $starttime = gettimeofday; > my @errors; >-my %opt; > my ( $confirm, $help, $test_parameter, $where ); > GetOptions( > 'c' => \$confirm, >@@ -110,5 +109,5 @@ if ( scalar(@errors) > 0 ) { > > sub defnonull { > my $var = shift; >- defined $var and $var ne ""; >+ return defined $var && $var ne q{}; > } >-- >2.1.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 17447
:
56516
|
56578
|
58523
|
58524
|
58528
|
58529
|
58530
|
58531
|
58532
|
58533
|
58534
|
58537
|
58538
|
58539