Merge branch 'js/eol-on-ourselves'
[gitweb.git] / builtin / add.c
index bf5e676e4666d55ea0d5340cc5186f184424f2f1..36cad00ae6ddad2b181da0b51294e1fe86aef788 100644 (file)
@@ -400,7 +400,7 @@ int cmd_add(int argc, const char **argv, const char *prefix)
                }
 
                /* This picks up the paths that are not tracked */
-               baselen = fill_directory(&dir, &pathspec);
+               baselen = fill_directory(&dir, &the_index, &pathspec);
                if (pathspec.nr)
                        seen = prune_directory(&dir, &pathspec, baselen);
        }
@@ -436,7 +436,7 @@ int cmd_add(int argc, const char **argv, const char *prefix)
                             !file_exists(path))) {
                                if (ignore_missing) {
                                        int dtype = DT_UNKNOWN;
-                                       if (is_excluded(&dir, path, &dtype))
+                                       if (is_excluded(&dir, &the_index, path, &dtype))
                                                dir_add_ignored(&dir, &the_index,
                                                                path, pathspec.items[i].len);
                                } else