diff --git a/builtin-update-index.c b/builtin-update-index.c
index 24dca47d8d6e54429aa89b04e4d67bda04fa0173..9f0cf28ba2dde7c5000029107460a3f4ca873aa3 100644 (file)
--- a/builtin-update-index.c
+++ b/builtin-update-index.c
static int info_only;
static int force_remove;
static int verbose;
-static int mark_valid_only = 0;
+static int mark_valid_only;
#define MARK_VALID 1
#define UNMARK_VALID 2
/* We can't free this memory, it becomes part of a linked list parsed atexit() */
lock_file = xcalloc(1, sizeof(struct lock_file));
- newfd = hold_lock_file_for_update(lock_file, get_index_file());
- if (newfd < 0)
- die("unable to create new cachefile");
+ newfd = hold_lock_file_for_update(lock_file, get_index_file(), 1);
entries = read_cache();
if (entries < 0)