X-Git-Url: https://asedeno.scripts.mit.edu/gitweb/?a=blobdiff_plain;f=bundle.c;h=0ba5df17e15d679b03fe38af40260c118c9588fa;hb=660b9c3a4e24ce9a2628f2ec88902e2384d1aade;hp=4352ce817f0488face752bd40d630255fe6ca186;hpb=e72ae28895b22052b7ca2eef36c039ac62671f7d;p=git.git diff --git a/bundle.c b/bundle.c index 4352ce817..0ba5df17e 100644 --- a/bundle.c +++ b/bundle.c @@ -336,8 +336,9 @@ int create_bundle(struct bundle_header *header, const char *path, close(rls.in); if (finish_command(&rls)) return error ("pack-objects died"); - - return bundle_to_stdout ? close(bundle_fd) : commit_lock_file(&lock); + if (!bundle_to_stdout) + commit_lock_file(&lock); + return 0; } int unbundle(struct bundle_header *header, int bundle_fd)