summaryrefslogtreecommitdiff
path: root/builtin
diff options
context:
space:
mode:
Diffstat (limited to 'builtin')
-rw-r--r--builtin/commit.c2
-rw-r--r--builtin/ls-files.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/builtin/commit.c b/builtin/commit.c
index 3b4dd60..4ee9ba6 100644
--- a/builtin/commit.c
+++ b/builtin/commit.c
@@ -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);
}
diff --git a/builtin/ls-files.c b/builtin/ls-files.c
index fa1a6be..c074e6f 100644
--- a/builtin/ls-files.c
+++ b/builtin/ls-files.c
@@ -546,7 +546,7 @@ int cmd_ls_files(int argc, const char **argv, const char *cmd_prefix)
prefix, argv);
/* Find common prefix for all pathspec's */
- max_prefix = common_prefix(pathspec.raw);
+ max_prefix = common_prefix(&pathspec);
max_prefix_len = max_prefix ? strlen(max_prefix) : 0;
/* Treat unmatching pathspec elements as errors */