Merge branch 'js/bundle-verify-require-object-store'
[gitweb.git] / builtin / update-index.c
index 1b6c42f748fd52ece4cf5f109f92a50bc2a87be3..27db0928bf052b0c518bee57ffa7cdd6c03d5d85 100644 (file)
@@ -597,7 +597,7 @@ static struct cache_entry *read_one_ent(const char *which,
                                        struct object_id *ent, const char *path,
                                        int namelen, int stage)
 {
-       unsigned mode;
+       unsigned short mode;
        struct object_id oid;
        struct cache_entry *ce;
 
@@ -724,7 +724,7 @@ static int do_unresolve(int ac, const char **av,
 }
 
 static int do_reupdate(int ac, const char **av,
-                      const char *prefix, int prefix_length)
+                      const char *prefix)
 {
        /* Read HEAD and run update-index on paths that are
         * merged and already different between index and HEAD.
@@ -940,8 +940,7 @@ static enum parse_opt_result reupdate_callback(
 
        /* consume remaining arguments. */
        setup_work_tree();
-       *has_errors = do_reupdate(ctx->argc, ctx->argv,
-                               prefix, prefix ? strlen(prefix) : 0);
+       *has_errors = do_reupdate(ctx->argc, ctx->argv, prefix);
        if (*has_errors)
                active_cache_changed = 0;
 
@@ -1082,6 +1081,8 @@ int cmd_update_index(int argc, const char **argv, const char *prefix)
        if (entries < 0)
                die("cache corrupted");
 
+       the_index.updated_skipworktree = 1;
+
        /*
         * Custom copy of parse_options() because we want to handle
         * filename arguments as they come.