diff options
author | Pascal Terjan <pterjan@mageia.org> | 2013-01-11 00:35:32 +0000 |
---|---|---|
committer | Pascal Terjan <pterjan@mageia.org> | 2013-01-11 00:35:32 +0000 |
commit | dbb4267e2c8eed73bf7d1fd538755104f3bf7234 (patch) | |
tree | 8c691256c145fe18bb4b23e9cdc1c33a87c602c5 /ulri | |
parent | 7344e2310917ec125218fc982bd447b1888c4b6c (diff) | |
download | iurt-dbb4267e2c8eed73bf7d1fd538755104f3bf7234.tar iurt-dbb4267e2c8eed73bf7d1fd538755104f3bf7234.tar.gz iurt-dbb4267e2c8eed73bf7d1fd538755104f3bf7234.tar.bz2 iurt-dbb4267e2c8eed73bf7d1fd538755104f3bf7234.tar.xz iurt-dbb4267e2c8eed73bf7d1fd538755104f3bf7234.zip |
Do not mark an arch done until all files are copied
Diffstat (limited to 'ulri')
-rwxr-xr-x | ulri | 15 |
1 files changed, 9 insertions, 6 deletions
@@ -376,7 +376,6 @@ foreach my $prefix (keys %pkg_tree) { $result =~ /^$prefix/ and next; my $result_file = "$done_dir/${prefix}_$result"; - my $done_file = "$done_dir/${prefix}_$arch.done"; plog('OK', "build ok: $result"); if ($result =~ /\.$arch_check\.rpm$/) { @@ -390,14 +389,18 @@ foreach my $prefix (keys %pkg_tree) { plog('ERROR', "copying $result from $host failed ($!)"); $error = 1; last; - } elsif (move("$result_file.new", $result_file)) { - if ($done) { - create_file($done_file, "$bot $host"); - $success = 1; - } + } + if (!move("$result_file.new", $result_file)) { + $error = 1; + last; } } next if $error; + + if ($done) { + create_file("$done_dir/${prefix}_$arch.done", "$bot $host"); + $success = 1; + } if ($success) { # Fetch build log and clean remote machine |