From 77444634e12eb13c2986a83384c4c9a6968c5334 Mon Sep 17 00:00:00 2001 From: teastep Date: Mon, 9 Mar 2009 21:45:30 +0000 Subject: [PATCH] Correct fatal error message generated by assert() Signed-off-by: Tom Eastep git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@9675 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb --- Shorewall/Perl/Shorewall/Config.pm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Shorewall/Perl/Shorewall/Config.pm b/Shorewall/Perl/Shorewall/Config.pm index 05cb391e6..eeed9692b 100644 --- a/Shorewall/Perl/Shorewall/Config.pm +++ b/Shorewall/Perl/Shorewall/Config.pm @@ -708,9 +708,10 @@ sub fatal_error1 { # sub assert( $ ) { unless ( $_[0] ) { - my @caller = caller 1; + my @caller0 = caller 0; # Where assert() was called + my @caller1 = caller 1; # Who called assert() - fatal_error "Internal error in $caller[0]::$caller[3]"; + fatal_error "Internal error in $caller1[3] at $caller0[1] line $caller0[2]"; } }