From 61a2c4db6adfa18ccd3b403cf7ccb12a0df9efd7 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Mon, 9 Mar 2020 15:59:41 +0100 Subject: [PATCH] Bug 24545: Cannot return outside of sub We must die instead Signed-off-by: Martin Renvoize --- xt/find-license-problems.t | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xt/find-license-problems.t b/xt/find-license-problems.t index 0df167d6b3..de89e931ca 100755 --- a/xt/find-license-problems.t +++ b/xt/find-license-problems.t @@ -42,7 +42,7 @@ sub wanted { find({ wanted => \&wanted, no_chdir => 1 }, File::Spec->curdir()); foreach my $name (@files) { - open( FILE, $name ) || return 0; + open( FILE, $name ) || die "cannot open file $name $!"; my ( $hascopyright, $hasgpl, $hasv3, $hasorlater, $haslinktolicense, $hasfranklinst, $is_not_us ) = (0)x7; while ( my $line = ) { -- 2.39.5