From ebba259fdcfd8cffe61000b48f11651fe8dd48b3 Mon Sep 17 00:00:00 2001 From: Andreas Guldstrand Date: Sat, 21 May 2016 23:20:25 +0200 Subject: SBO::Lib: document race condition in git_sbo_tree where $repo_path can be deleted --- SBO-Lib/lib/SBO/Lib.pm | 1 + 1 file changed, 1 insertion(+) (limited to 'SBO-Lib/lib') diff --git a/SBO-Lib/lib/SBO/Lib.pm b/SBO-Lib/lib/SBO/Lib.pm index 8bd7e37..a090d01 100644 --- a/SBO-Lib/lib/SBO/Lib.pm +++ b/SBO-Lib/lib/SBO/Lib.pm @@ -330,6 +330,7 @@ sub git_sbo_tree { my $cwd = getcwd(); my $res; if (-d "$repo_path/.git" and check_git_remote($repo_path, $url)) { + _race::cond '$repo_path can be deleted after -d check'; chdir $repo_path; $res = eval { die unless system(qw! git fetch !) == 0; # if system() doesn't return 0, there was an error -- cgit v1.2.3