aboutsummaryrefslogtreecommitdiffstats
path: root/iurt2
diff options
context:
space:
mode:
authorFlorent Villard <warly@mandriva.com>2005-12-13 07:14:19 +0000
committerFlorent Villard <warly@mandriva.com>2005-12-13 07:14:19 +0000
commitfd63c6ef5a164be3d15607113500080cd58dfce1 (patch)
tree9ac054e8b9fc5cb8cb1febfd78bcbe541d5fcb70 /iurt2
parent09d0bd09fe9e6d473f3a7496a306dea7b6c68062 (diff)
downloadiurt-fd63c6ef5a164be3d15607113500080cd58dfce1.tar
iurt-fd63c6ef5a164be3d15607113500080cd58dfce1.tar.gz
iurt-fd63c6ef5a164be3d15607113500080cd58dfce1.tar.bz2
iurt-fd63c6ef5a164be3d15607113500080cd58dfce1.tar.xz
iurt-fd63c6ef5a164be3d15607113500080cd58dfce1.zip
Fix command execution failure check
Diffstat (limited to 'iurt2')
-rwxr-xr-xiurt23
1 files changed, 1 insertions, 2 deletions
diff --git a/iurt2 b/iurt2
index b5a8ac2..ada7cc3 100755
--- a/iurt2
+++ b/iurt2
@@ -425,7 +425,6 @@ sub fix_srpm_name {
sub perform_command {
my ($command, %opt) = @_;
- # my ($command, $mail, $error, $hash, $die, $timeout, $cc, $log, $freq) = @_;
$opt{timeout} ||= 300;
$opt{freq} ||= 24;
print "Timeout $opt{timeout}\n";
@@ -442,7 +441,7 @@ sub perform_command {
}
# FIXME process goes in defunct always, kill -14 should unsleep it, but not
kill 9, $pid;
- if ($? || $opt{error_regexp} ? $output =~ /$opt{error_regexp}/ : 1) {
+ if ($? || $opt{error_regexp} && $output =~ /$opt{error_regexp}/) {
if ($opt{mail}) {
if ($::warning->{$opt{hash}}{$my_arch}{$opt{mail}} % $opt{freq}) {
sendmail($opt{mail}, $opt{cc} , $opt{error} , $output, 0, 0);