summaryrefslogtreecommitdiff
path: root/diff.c
diff options
context:
space:
mode:
Diffstat (limited to 'diff.c')
-rw-r--r--diff.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/diff.c b/diff.c
index a628ac3a95..70870b4b69 100644
--- a/diff.c
+++ b/diff.c
@@ -4023,7 +4023,7 @@ int diff_opt_parse(struct diff_options *options,
else if (!strcmp(arg, "--pickaxe-regex"))
options->pickaxe_opts |= DIFF_PICKAXE_REGEX;
else if ((argcount = short_opt('O', av, &optarg))) {
- const char *path = prefix_filename(prefix, strlen(prefix), optarg);
+ const char *path = prefix_filename(prefix, optarg);
options->orderfile = xstrdup(path);
return argcount;
}
@@ -4071,7 +4071,7 @@ int diff_opt_parse(struct diff_options *options,
else if (!strcmp(arg, "--no-function-context"))
DIFF_OPT_CLR(options, FUNCCONTEXT);
else if ((argcount = parse_long_opt("output", av, &optarg))) {
- const char *path = prefix_filename(prefix, strlen(prefix), optarg);
+ const char *path = prefix_filename(prefix, optarg);
options->file = fopen(path, "w");
if (!options->file)
die_errno("Could not open '%s'", path);