remove match_pathspec() in favor of match_pathspec_depth()
[gitweb.git] / builtin / commit.c
index eaecf7c494d4b8bb2ccc656e9003c2a34f28932f..4ee9ba6c63857de0689947ab51a7bcbc95b33259 100644 (file)
@@ -199,7 +199,7 @@ static int list_paths(struct string_list *list, const char *with_tree,
        m = xcalloc(1, pattern->nr);
 
        if (with_tree) {
-               char *max_prefix = common_prefix(pattern->raw);
+               char *max_prefix = common_prefix(pattern);
                overlay_tree_on_cache(with_tree, max_prefix ? max_prefix : prefix);
                free(max_prefix);
        }
@@ -336,7 +336,7 @@ static char *prepare_index(int argc, const char **argv, const char *prefix,
         */
        if (all || (also && pathspec.nr)) {
                fd = hold_locked_index(&index_lock, 1);
-               add_files_to_cache(also ? prefix : NULL, pathspec.raw, 0);
+               add_files_to_cache(also ? prefix : NULL, &pathspec, 0);
                refresh_cache_or_die(refresh_flags);
                update_main_cache_tree(WRITE_TREE_SILENT);
                if (write_cache(fd, active_cache, active_nr) ||
@@ -1244,7 +1244,7 @@ int cmd_status(int argc, const char **argv, const char *prefix)
                       prefix, argv);
 
        read_cache_preload(&s.pathspec);
-       refresh_index(&the_index, REFRESH_QUIET|REFRESH_UNMERGED, s.pathspec.raw, NULL, NULL);
+       refresh_index(&the_index, REFRESH_QUIET|REFRESH_UNMERGED, &s.pathspec, NULL, NULL);
 
        fd = hold_locked_index(&index_lock, 0);
        if (0 <= fd)