Bugzilla – Attachment 8632 Details for
Bug 7829
reports/ remove all exit(1) for plack
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 7829 - reports/ remove all exit(1) for plack
Bug-7829---reports-remove-all-exit1-for-plack.patch (text/plain), 6.27 KB, created by
Dobrica Pavlinusic
on 2012-03-26 14:52:30 UTC
(
hide
)
Description:
Bug 7829 - reports/ remove all exit(1) for plack
Filename:
MIME Type:
Creator:
Dobrica Pavlinusic
Created:
2012-03-26 14:52:30 UTC
Size:
6.27 KB
patch
obsolete
>From a89df65e89771ddbfb16fbd8a0281b8d66ee37c1 Mon Sep 17 00:00:00 2001 >From: Dobrica Pavlinusic <dpavlin@rot13.org> >Date: Mon, 26 Mar 2012 16:49:12 +0200 >Subject: [PATCH] Bug 7829 - reports/ remove all exit(1) for plack > >In Bug 7772 Ian correctly noted that reports have exit(1) all over the place. >This is left over from old code, and this patch changes them to exit(0). > >I decided to use plain exit as opposed to explicit exit(0) since it produces >cleaner code, but I'm welcoming suggestion on this. >--- > reports/acquisitions_stats.pl | 2 +- > reports/bor_issues_top.pl | 2 +- > reports/borrowers_out.pl | 4 ++-- > reports/borrowers_stats.pl | 2 +- > reports/cat_issues_top.pl | 4 ++-- > reports/catalogue_out.pl | 2 +- > reports/catalogue_stats.pl | 4 ++-- > reports/issues_avg_stats.pl | 4 ++-- > reports/issues_stats.pl | 2 +- > reports/reserves_stats.pl | 2 +- > reports/serials_stats.pl | 2 +- > 11 files changed, 15 insertions(+), 15 deletions(-) > >diff --git a/reports/acquisitions_stats.pl b/reports/acquisitions_stats.pl >index ad0ac3f..7207e64 100755 >--- a/reports/acquisitions_stats.pl >+++ b/reports/acquisitions_stats.pl >@@ -108,7 +108,7 @@ if ($do_it) { > } > print $sep. @$results[0]->{total}; > } >- exit(1); >+ exit; > } > else { > my $dbh = C4::Context->dbh; >diff --git a/reports/bor_issues_top.pl b/reports/bor_issues_top.pl >index 126cdef..6ad3495 100755 >--- a/reports/bor_issues_top.pl >+++ b/reports/bor_issues_top.pl >@@ -102,7 +102,7 @@ if ($do_it) { > print join($sep, map {$_->{totalcol}} @$cols); > print $sep.@$results[0]->{total}; > } >- exit(0); >+ exit; > } > > my $dbh = C4::Context->dbh; >diff --git a/reports/borrowers_out.pl b/reports/borrowers_out.pl >index 278e412..722faba 100755 >--- a/reports/borrowers_out.pl >+++ b/reports/borrowers_out.pl >@@ -69,7 +69,7 @@ if ($do_it) { > # Printing results to screen > $template->param(mainloop => $results); > output_html_with_http_headers $input, $cookie, $template->output; >- exit(1); >+ exit; > } else { > # Printing to a csv file > print $input->header(-type => 'application/vnd.sun.xml.calc', >@@ -103,7 +103,7 @@ if ($do_it) { > print $sep.$col->{totalcol}; > } > print $sep.@$results[0]->{total}; >- exit(1); >+ exit; > } > # Displaying choices > } else { >diff --git a/reports/borrowers_stats.pl b/reports/borrowers_stats.pl >index c17a326..9e00ea3 100755 >--- a/reports/borrowers_stats.pl >+++ b/reports/borrowers_stats.pl >@@ -107,7 +107,7 @@ if ($do_it) { > } > print $sep.@$results[0]->{total}; > } >- exit(1); # exit after do_it, regardless >+ exit; # exit after do_it, regardless > } else { > my $dbh = C4::Context->dbh; > my $req; >diff --git a/reports/cat_issues_top.pl b/reports/cat_issues_top.pl >index 606106d..2a6409d 100755 >--- a/reports/cat_issues_top.pl >+++ b/reports/cat_issues_top.pl >@@ -75,7 +75,7 @@ if ($do_it) { > $template->param(mainloop => $results, > limit => $limit); > output_html_with_http_headers $input, $cookie, $template->output; >- exit(1); >+ exit; > } else { > # Printing to a csv file > print $input->header(-type => 'application/vnd.sun.xml.calc', >@@ -108,7 +108,7 @@ if ($do_it) { > print $sep.$col->{totalcol}; > } > print $sep.@$results[0]->{total}; >- exit(1); >+ exit; > } > # Displaying choices > } else { >diff --git a/reports/catalogue_out.pl b/reports/catalogue_out.pl >index 87990c1..8a22a18 100755 >--- a/reports/catalogue_out.pl >+++ b/reports/catalogue_out.pl >@@ -96,7 +96,7 @@ if ($do_it) { > } > print $sep.@$results[0]->{total}; > } >- exit(1); # in either case, exit after do_it >+ exit; # in either case, exit after do_it > } > > # Displaying choices (i.e., not do_it) >diff --git a/reports/catalogue_stats.pl b/reports/catalogue_stats.pl >index 11dff4d..c8e2194 100755 >--- a/reports/catalogue_stats.pl >+++ b/reports/catalogue_stats.pl >@@ -74,7 +74,7 @@ if ($do_it) { > if ($output eq "screen"){ > $template->param(mainloop => $results); > output_html_with_http_headers $input, $cookie, $template->output; >- exit(1); >+ exit; > } else { > print $input->header(-type => 'application/vnd.sun.xml.calc', > -encoding => 'utf-8', >@@ -102,7 +102,7 @@ if ($do_it) { > print $sep.$col->{totalcol}; > } > print $sep.@$results[0]->{total}; >- exit(1); >+ exit; > } > } else { > my $dbh = C4::Context->dbh; >diff --git a/reports/issues_avg_stats.pl b/reports/issues_avg_stats.pl >index c6a3859..372f3c0 100755 >--- a/reports/issues_avg_stats.pl >+++ b/reports/issues_avg_stats.pl >@@ -77,7 +77,7 @@ if ($do_it) { > # Printing results to screen > $template->param(mainloop => $results); > output_html_with_http_headers $input, $cookie, $template->output; >- exit(1); >+ exit; > } else { > # Printing to a csv file > print $input->header(-type => 'application/vnd.sun.xml.calc', >@@ -110,7 +110,7 @@ if ($do_it) { > print $sep.$col->{totalcol}; > } > print $sep.@$results[0]->{total}; >- exit(1); >+ exit; > } > # Displaying choices > } else { >diff --git a/reports/issues_stats.pl b/reports/issues_stats.pl >index 2f8a7e3..4b6aa42 100755 >--- a/reports/issues_stats.pl >+++ b/reports/issues_stats.pl >@@ -123,7 +123,7 @@ if ($do_it) { > print map {$sep.$_->{totalcol}} @$cols; > print $sep.@$results[0]->{total}; > } >- exit(1); # exit either way after $do_it >+ exit; # exit either way after $do_it > } > > my $dbh = C4::Context->dbh; >diff --git a/reports/reserves_stats.pl b/reports/reserves_stats.pl >index a2b3737..c20a676 100755 >--- a/reports/reserves_stats.pl >+++ b/reports/reserves_stats.pl >@@ -130,7 +130,7 @@ if ($do_it) { > print map {$sep.$_->{totalcol}} @$cols; > print $sep.@$results[0]->{total}; > } >- exit(1); # exit either way after $do_it >+ exit; # exit either way after $do_it > } > > my $dbh = C4::Context->dbh; >diff --git a/reports/serials_stats.pl b/reports/serials_stats.pl >index 88918cc..ff80b2f 100755 >--- a/reports/serials_stats.pl >+++ b/reports/serials_stats.pl >@@ -125,7 +125,7 @@ if($do_it){ > print $item->{startdate}.$sep; > print $item->{enddate}."\n"; > } >- exit(1); >+ exit; > } > }else{ > ## We generate booksellers list >-- >1.7.2.5
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 7829
:
8632
|
8644