diff options
author | Junio C Hamano <gitster@pobox.com> | 2017-03-27 10:59:26 -0700 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-03-27 10:59:26 -0700 |
commit | a026bde1ac84f90f0b82faa18890b2023c5198d5 (patch) | |
tree | 8e976b861d4b23904c09bb1fbdd8004f37cb6e6f /parse-options.c | |
parent | 09fb53568e3e00e30891b118045aa07ede524103 (diff) | |
parent | 3b754eedd58636926d07b14a34799a3aa7b8ebc2 (diff) | |
download | git-a026bde1ac84f90f0b82faa18890b2023c5198d5.tar.gz |
Merge branch 'jk/prefix-filename'
Code clean-up with minor bugfixes.
* jk/prefix-filename:
bundle: use prefix_filename with bundle path
prefix_filename: simplify windows #ifdef
prefix_filename: return newly allocated string
prefix_filename: drop length parameter
prefix_filename: move docstring to header file
hash-object: fix buffer reuse with --path in a subdirectory
Diffstat (limited to 'parse-options.c')
-rw-r--r-- | parse-options.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/parse-options.c b/parse-options.c index 4fbe924a5d..a23a1e67f0 100644 --- a/parse-options.c +++ b/parse-options.c @@ -40,7 +40,7 @@ static void fix_filename(const char *prefix, const char **file) if (!file || !*file || !prefix || is_absolute_path(*file) || !strcmp("-", *file)) return; - *file = xstrdup(prefix_filename(prefix, strlen(prefix), *file)); + *file = prefix_filename(prefix, *file); } static int opt_command_mode_error(const struct option *opt, |