[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[lintian] 03/05: t/runtests: Fix potential error-hiding bug



This is an automated email from the git hooks/post-receive script.

nthykier pushed a commit to branch master
in repository lintian.

commit bc398b7511d7d733f53c97a16b765b6fa01a29a8
Author: Niels Thykier <niels@thykier.net>
Date:   Mon Mar 24 19:31:33 2014 +0100

    t/runtests: Fix potential error-hiding bug
    
    Signed-off-by: Niels Thykier <niels@thykier.net>
---
 t/runtests | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/t/runtests b/t/runtests
index 6de9cc3..a0cf169 100755
--- a/t/runtests
+++ b/t/runtests
@@ -884,9 +884,9 @@ sub run_tests{
                 while (my $t = $q->dequeue_nb()) {
                     my $okay = eval { $code->($t); };
                     if (!$okay || $@) {
-                        if ($@) {
+                        if (my $err = $@) {
                             msg_print "FAILED\n";
-                            print STDERR "$@\n";
+                            print STDERR "$err\n";
                         }
                         exit 1 unless $run_all_tests;
                         my $name = $t;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git


Reply to: