diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2002-08-27 19:28:03 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2002-08-27 19:28:03 +0000 |
commit | 997fbf5986136dfd2a2a81ec692fd575ce66478c (patch) | |
tree | cdb56aaa57503881dc1f4e1d5fa5133cef1e80c4 /MDK/Common | |
parent | c41f2074e1e51edbd5f266691cd9d21ecd013a95 (diff) | |
download | perl-MDK-Common-997fbf5986136dfd2a2a81ec692fd575ce66478c.tar perl-MDK-Common-997fbf5986136dfd2a2a81ec692fd575ce66478c.tar.gz perl-MDK-Common-997fbf5986136dfd2a2a81ec692fd575ce66478c.tar.bz2 perl-MDK-Common-997fbf5986136dfd2a2a81ec692fd575ce66478c.tar.xz perl-MDK-Common-997fbf5986136dfd2a2a81ec692fd575ce66478c.zip |
give a meaning to the return value of cdie
Diffstat (limited to 'MDK/Common')
-rw-r--r-- | MDK/Common/Func.pm | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/MDK/Common/Func.pm b/MDK/Common/Func.pm index 6578010..56e032a 100644 --- a/MDK/Common/Func.pm +++ b/MDK/Common/Func.pm @@ -280,10 +280,12 @@ sub catch_cdie(&&) { } sub cdie { - my ($err, $f) = @_; + my ($err) = @_; foreach (@MDK::Common::Func::cdie_catches) { $@ = $err; - &{$_}(\$err) and return; + if (my $v = &{$_}(\$err)) { + return $v; + } } die $err; } |