summaryrefslogtreecommitdiff
path: root/src/diff_output.c
diff options
context:
space:
mode:
authorRussell Belfer <rb@github.com>2012-11-09 11:19:46 -0800
committerRussell Belfer <rb@github.com>2012-11-09 13:52:07 -0800
commit0f3def715dc9af442f5f025c50a041c6319df1e8 (patch)
treee5a327bab384ab865471d019c83637b6ed167e3c /src/diff_output.c
parent8064ecba2384df32d5b821398a346f0c96cf74d1 (diff)
downloadlibgit2-0f3def715dc9af442f5f025c50a041c6319df1e8.tar.gz
Fix various cross-platform build issues
This fixes a number of warnings and problems with cross-platform builds. Among other things, it's not safe to name a member of a structure "strcmp" because that may be #defined.
Diffstat (limited to 'src/diff_output.c')
-rw-r--r--src/diff_output.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/diff_output.c b/src/diff_output.c
index 2f61540ff..46a9e02bf 100644
--- a/src/diff_output.c
+++ b/src/diff_output.c
@@ -120,7 +120,7 @@ static int diff_delta_is_binary_by_attr(
return -1;
mirror_new = (delta->new_file.path == delta->old_file.path ||
- strcmp(delta->new_file.path, delta->old_file.path) == 0);
+ ctxt->diff->strcomp(delta->new_file.path, delta->old_file.path) == 0);
if (mirror_new)
delta->new_file.flags |= (delta->old_file.flags & KNOWN_BINARY_FLAGS);
else
@@ -1002,7 +1002,7 @@ static int print_compact(
git_buf_clear(pi->buf);
if (delta->old_file.path != delta->new_file.path &&
- strcmp(delta->old_file.path,delta->new_file.path) != 0)
+ pi->diff->strcomp(delta->old_file.path,delta->new_file.path) != 0)
git_buf_printf(pi->buf, "%c\t%s%c -> %s%c\n", code,
delta->old_file.path, old_suffix, delta->new_file.path, new_suffix);
else if (delta->old_file.mode != delta->new_file.mode &&