Skip to content

Commit 1ebd5b5

Browse files
committed
Merge branch 'master' into next
* master: convert.c: Fix return type of git_path_check_eol() documentation fix: git difftool uses diff tools, not merge tools. config.c: Fix a static buffer overwrite bug by avoiding mkpath() t5501-*.sh: Fix url passed to clone in setup test
2 parents 872f25e + e14d631 commit 1ebd5b5

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

Documentation/git-difftool.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ OPTIONS
3131
-t <tool>::
3232
--tool=<tool>::
3333
Use the diff tool specified by <tool>.
34-
Valid merge tools are:
34+
Valid diff tools are:
3535
araxis, bc3, diffuse, emerge, ecmerge, gvimdiff, kdiff3,
3636
kompare, meld, opendiff, p4merge, tkdiff, vimdiff and xxdiff.
3737
+

config.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -886,12 +886,12 @@ int git_config_early(config_fn_t fn, void *data, const char *repo_config)
886886

887887
home = getenv("HOME");
888888
if (home) {
889-
char *user_config = xstrdup(mkpath("%s/.gitconfig", home));
889+
char buf[PATH_MAX];
890+
char *user_config = mksnpath(buf, sizeof(buf), "%s/.gitconfig", home);
890891
if (!access(user_config, R_OK)) {
891892
ret += git_config_from_file(fn, user_config, data);
892893
found += 1;
893894
}
894-
free(user_config);
895895
}
896896

897897
if (repo_config && !access(repo_config, R_OK)) {

convert.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,7 @@ static enum crlf_action git_path_check_crlf(const char *path, struct git_attr_ch
658658
return CRLF_GUESS;
659659
}
660660

661-
static enum crlf_action git_path_check_eol(const char *path, struct git_attr_check *check)
661+
static enum eol git_path_check_eol(const char *path, struct git_attr_check *check)
662662
{
663663
const char *value = check->value;
664664

t/t5501-fetch-push-alternates.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ test_expect_success setup '
2828
done
2929
) &&
3030
(
31-
git clone --reference=original "file:///$(pwd)/original" one &&
31+
git clone --reference=original "file://$(pwd)/original" one &&
3232
cd one &&
3333
echo Z >count &&
3434
git add count &&

0 commit comments

Comments
 (0)