Commit 738b235c authored by Matthieu Muffato's avatar Matthieu Muffato
Browse files

Only attempt deleting the directory if the worker belongs to the same user

parent ce64063b
......@@ -442,7 +442,10 @@ sub check_for_dead_workers { # scans the whole Valley for lost Workers (but i
$worker->when_died( $report_entries->{$process_id}{'when_died'} );
$worker->cause_of_death( $report_entries->{$process_id}{'cause_of_death'} );
$self->register_worker_death( $worker );
$valley->cleanup_left_temp_directory( $worker );
if ($worker->meadow_user eq $ENV{'USER'}) { # if I'm actually allowed to kill the worker...
warn "GarbageCollector:\tCleaning-up /tmp\n";
$valley->cleanup_left_temp_directory( $worker );
}
}
if( %$report_entries ) { # use the opportunity to also store resource usage of the buried workers:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment