Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Make sure there's a filename to unlink
  • Loading branch information
MasterDuke17 committed Aug 22, 2016
1 parent 4a65abd commit 635f61a
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Benchable.p6
Expand Up @@ -195,7 +195,7 @@ Z: loop (my int $x = 0; $x < +@commits - 1; $x++) {

LEAVE {
chdir $old-dir;
unlink $filename;
unlink $filename if $filename.defined and $filename.chars > 0;
}
}

Expand Down
6 changes: 3 additions & 3 deletions Bisectable.p6
Expand Up @@ -231,9 +231,9 @@ method process($message, $code is copy, $good, $bad) {

LEAVE {
chdir $old-dir;
unlink $output-file;
unlink $filename;
rmtree $dir;
unlink $output-file if $output-file.defined and $output-file.chars > 0;
unlink $filename if $filename.defined and $filename.chars > 0;
rmtree $dir if $dir.defined and $dir.chars > 0;
}
}

Expand Down
2 changes: 1 addition & 1 deletion Committable.p6
Expand Up @@ -107,7 +107,7 @@ method process($message, $config, $code is copy) {

LEAVE {
chdir $old_dir;
unlink $filename;
unlink $filename if $filename.defined and $filename.chars > 0;
}
}

Expand Down

0 comments on commit 635f61a

Please sign in to comment.