Report handbrake failure to client
Added check on return status of handbrake process, and reports failure to cluster client. Fixed a bug whereby handbrake processes were not reaped after the rip completes
This commit is contained in:
@@ -125,6 +125,16 @@ sub do_rip {
|
||||
while ($line = <$child_out>) {
|
||||
$log->debug($line);
|
||||
}
|
||||
close($child_out);
|
||||
|
||||
# If the rip process failed, report an error status here
|
||||
waitpid($child_pid, 0);
|
||||
my $child_exit_status = $? >> 8;
|
||||
|
||||
if (!$child_exit_status) {
|
||||
$log->warning("Ripping process returned error status: $child_exit_status");
|
||||
return undef;
|
||||
}
|
||||
|
||||
$log->notice("Finished rip to $rip_filename");
|
||||
return $rip_filename;
|
||||
|
||||
Reference in New Issue
Block a user