diff options
author | Jeff King <peff@peff.net> | 2017-04-20 17:08:54 -0400 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2017-04-20 21:03:51 -0700 |
commit | ca03e0670c3ba71400b0f5ed199b045481efdb1e (patch) | |
tree | 75e3edb9762cb9caa8a84a09b12a6da97865d3e8 /builtin/commit.c | |
parent | c10388c7dc89ec4f8a6c1f7b1fd15d70e8ee0f07 (diff) | |
download | git-ca03e0670c3ba71400b0f5ed199b045481efdb1e.tar.gz git-ca03e0670c3ba71400b0f5ed199b045481efdb1e.tar.xz |
use git_path_* helper functions
Long ago we added functions like git_path_merge_msg() to
replace the more dangerous git_path("MERGE_MSG"). Over time
some new calls to the latter have crept it. Let's convert
them to use the safer form.
Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/commit.c')
-rw-r--r-- | builtin/commit.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/builtin/commit.c b/builtin/commit.c index 2de5f6cc6..bbaa4a0da 100644 --- a/builtin/commit.c +++ b/builtin/commit.c @@ -821,9 +821,9 @@ static int prepare_to_commit(const char *index_file, const char *prefix, "If this is not correct, please remove the file\n" " %s\n" "and try again.\n"), - git_path(whence == FROM_MERGE - ? "MERGE_HEAD" - : "CHERRY_PICK_HEAD")); + whence == FROM_MERGE ? + git_path_merge_head() : + git_path_cherry_pick_head()); } fprintf(s->fp, "\n"); |