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>
This commit is contained in:
@ -320,7 +320,8 @@ static char *prepare_index(int argc, const char **argv, const char *prefix)
|
||||
die("unable to write new_index file");
|
||||
|
||||
fd = hold_lock_file_for_update(&false_lock,
|
||||
git_path("next-index-%d", getpid()), 1);
|
||||
git_path("next-index-%d", getpid()),
|
||||
LOCK_DIE_ON_ERROR);
|
||||
|
||||
create_base_index();
|
||||
add_remove_files(&partial);
|
||||
|
Reference in New Issue
Block a user