Makefile: consolidate .FORCE-* targets
[gitweb.git] / builtin-read-tree.c
index 14c836b1693317d5d834606e5613d7ceacb3189c..2a3a32cbfe83a0e0366d04a99bb49606f647f594 100644 (file)
@@ -108,11 +108,11 @@ int cmd_read_tree(int argc, const char **argv, const char *unused_prefix)
 
        git_config(git_default_config, NULL);
 
-       newfd = hold_locked_index(&lock_file, 1);
-
        argc = parse_options(argc, argv, unused_prefix, read_tree_options,
                             read_tree_usage, 0);
 
+       newfd = hold_locked_index(&lock_file, 1);
+
        prefix_set = opts.prefix ? 1 : 0;
        if (1 < opts.merge + opts.reset + prefix_set)
                die("Which one? -m, --reset, or --prefix?");