marsadm: prevent accumulation of .tmp remains

This commit is contained in:
Thomas Schoebel-Theuer 2017-11-12 17:05:34 +01:00 committed by Thomas Schoebel-Theuer
parent 2c74910b56
commit 5c27b2fcd4

View File

@ -2428,7 +2428,7 @@ sub logdelete_res {
lprint " unlink '$leftlink'\n" if $verbose;
system("rm -rf $leftlink");
}
foreach my $leftlink (glob("$mars/{,resource-$res/}{,*/}{.deleted,delete,work}-*")) {
foreach my $leftlink (glob("$mars/{,resource-$res/}{,*/}{.tmp,.deleted,delete,work}-*")) {
my $stamp = get_link_stamp($leftlink);
next unless $stamp + 3600 * 24 < $start_time;
lprint " unlink '$leftlink'\n" if $verbose;