diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-11-18 18:23:59 +0900 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-11-18 18:23:59 +0900 |
commit | 9e3dc6bfb2756f9da7ddb64a1d9e41a22aa11e9b (patch) | |
tree | 352407e77e35633cd1a63cca1c6d05275cb5f323 /t | |
parent | Merge branch 'ab/rebase-in-c-escape-hatch' (diff) | |
parent | bundle: dup() output descriptor closer to point-of-use (diff) | |
download | tgif-9e3dc6bfb2756f9da7ddb64a1d9e41a22aa11e9b.tar.xz |
Merge branch 'jk/close-duped-fd-before-unlock-for-bundle'
When "git bundle" aborts due to an empty commit ranges
(i.e. resulting in an empty pack), it left a file descriptor to an
lockfile open, which resulted in leftover lockfile on Windows where
you cannot remove a file with an open file descriptor. This has
been corrected.
* jk/close-duped-fd-before-unlock-for-bundle:
bundle: dup() output descriptor closer to point-of-use
Diffstat (limited to 't')
-rwxr-xr-x | t/t5607-clone-bundle.sh | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/t/t5607-clone-bundle.sh b/t/t5607-clone-bundle.sh index 348d9b3bc7..cf39e9e243 100755 --- a/t/t5607-clone-bundle.sh +++ b/t/t5607-clone-bundle.sh @@ -71,4 +71,10 @@ test_expect_success 'prerequisites with an empty commit message' ' git bundle verify bundle ' +test_expect_success 'failed bundle creation does not leave cruft' ' + # This fails because the bundle would be empty. + test_must_fail git bundle create fail.bundle master..master && + test_path_is_missing fail.bundle.lock +' + test_done |