From 472d1be45e2fd626ef8b62addd92eda351243bc0 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Tue, 9 Dec 2008 13:06:27 +0000 Subject: segfault must not go undetected! --- t/helper.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 't/helper.pm') diff --git a/t/helper.pm b/t/helper.pm index 511c4ab0..9df53b4c 100644 --- a/t/helper.pm +++ b/t/helper.pm @@ -135,7 +135,8 @@ sub system_ { sub system_should_fail { my ($cmd) = @_; system($cmd); - ok($? != 0, "should fail: $cmd"); + $? & 127 ? is($? & 127, 0, "should fail nicely but not get killed: $cmd") + : ok($? != 0, "should fail: $cmd"); } sub rpm_is_jbj_version { -- cgit v1.2.1