summaryrefslogtreecommitdiff
path: root/bundle.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2008-10-17 22:44:39 (GMT)
committerJunio C Hamano <gitster@pobox.com>2008-10-19 19:35:37 (GMT)
commitacd3b9eca82e38950f94e4708b528b7dae09a7c8 (patch)
treef341dae377b97e9c7fd9746208be0fee56bda438 /bundle.c
parentf5637549a7eb93883839de01399418e10bf81768 (diff)
downloadgit-acd3b9eca82e38950f94e4708b528b7dae09a7c8.zip
git-acd3b9eca82e38950f94e4708b528b7dae09a7c8.tar.gz
git-acd3b9eca82e38950f94e4708b528b7dae09a7c8.tar.bz2
Enhance hold_lock_file_for_{update,append}() API
This changes the "die_on_error" boolean parameter to a mere "flags", and changes the existing callers of hold_lock_file_for_update/append() functions to pass LOCK_DIE_ON_ERROR. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'bundle.c')
-rw-r--r--bundle.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/bundle.c b/bundle.c
index 00b2aab..7d17a1f 100644
--- a/bundle.c
+++ b/bundle.c
@@ -186,7 +186,8 @@ int create_bundle(struct bundle_header *header, const char *path,
if (bundle_to_stdout)
bundle_fd = 1;
else
- bundle_fd = hold_lock_file_for_update(&lock, path, 1);
+ bundle_fd = hold_lock_file_for_update(&lock, path,
+ LOCK_DIE_ON_ERROR);
/* write signature */
write_or_die(bundle_fd, bundle_signature, strlen(bundle_signature));