# HG changeset patch # User Vincent Tondellier # Date 1408395686 -7200 # Node ID 604ffca3aec119de9346ef7d5e33c9746e011280 # Parent f2292404519a66dd12f5af828b592a9dd85d72c0 Fix warnings with perl 5.20 diff -r f2292404519a -r 604ffca3aec1 CrashTest.pl --- a/CrashTest.pl Fri Aug 08 23:05:03 2014 +0200 +++ b/CrashTest.pl Mon Aug 18 23:01:26 2014 +0200 @@ -13,6 +13,8 @@ # You should have received a copy of the GNU General Public License # along with this program. If not, see . +# ABSTRACT: Web interface for breakpad + use Mojolicious::Lite; use UUID; use lib 'lib'; @@ -80,13 +82,13 @@ $crashing_thread = $stackfilter->apply($crashing_thread); $self->stash(crashing_thread => $crashing_thread); - my $threads = []; + my @threads = (); foreach my $raw_thread(@{$data->{threads}}) { my $thread = CrashTest::Models::Thread->new($raw_thread); $thread = $stackfilter->apply($thread); - push $threads, $thread; + push @threads, $thread; } - $self->stash(threads => $threads); + $self->stash(threads => \@threads); $self->render('report/crash'); } => 'report'; diff -r f2292404519a -r 604ffca3aec1 lib/CrashTest/StackFilter.pm --- a/lib/CrashTest/StackFilter.pm Fri Aug 08 23:05:03 2014 +0200 +++ b/lib/CrashTest/StackFilter.pm Mon Aug 18 23:01:26 2014 +0200 @@ -47,7 +47,7 @@ my $loader = Mojo::Loader->new; for my $module (@$modules) { my $e = $loader->load($module); - die qq{Loading "$module" failed: $e} and next if ref $e; + die qq{Loading "$module" failed: $e} if ref $e; #say "loading $module"; push @filters, $module->new(config => $self->config, app => $self->app); diff -r f2292404519a -r 604ffca3aec1 lib/CrashTest/Storage/Sql.pm --- a/lib/CrashTest/Storage/Sql.pm Fri Aug 08 23:05:03 2014 +0200 +++ b/lib/CrashTest/Storage/Sql.pm Mon Aug 18 23:01:26 2014 +0200 @@ -43,7 +43,7 @@ }; for my $crash($dbcrashs->all) { my $filename = File::Spec->catfile($self->{data_path}, $crash->uuid); - push $results->{crashs}, { + push @{$results->{crashs}}, { file => $filename, uuid => $crash->uuid, product => $crash->product->name,