]> git.ipfire.org Git - thirdparty/git.git/blobdiff - git-p4.py
Start the 2.46 cycle
[thirdparty/git.git] / git-p4.py
index 156597adb59f33d049b9ef81f10b7fda283eca3d..28ab12c72b6561bf6f583391acf8daa300a6211b 100755 (executable)
--- a/git-p4.py
+++ b/git-p4.py
@@ -4251,7 +4251,8 @@ class P4Sync(Command, P4UserMap):
         if self.tempBranches != []:
             for branch in self.tempBranches:
                 read_pipe(["git", "update-ref", "-d", branch])
-            os.rmdir(os.path.join(os.environ.get("GIT_DIR", ".git"), self.tempBranchLocation))
+            if len(read_pipe(["git", "for-each-ref", self.tempBranchLocation])) > 0:
+                   die("There are unexpected temporary branches")
 
         # Create a symbolic ref p4/HEAD pointing to p4/<branch> to allow
         # a convenient shortcut refname "p4".