Commit 81b7dec4 by Russell Belfer

Fix some compile warnings and trailing whitespace

parent d82d66c9
...@@ -193,44 +193,46 @@ static int conflict_name_cmp(const void *a, const void *b) ...@@ -193,44 +193,46 @@ static int conflict_name_cmp(const void *a, const void *b)
{ {
const git_index_name_entry *name_a = a; const git_index_name_entry *name_a = a;
const git_index_name_entry *name_b = b; const git_index_name_entry *name_b = b;
if (name_a->ancestor && !name_b->ancestor) if (name_a->ancestor && !name_b->ancestor)
return 1; return 1;
if (!name_a->ancestor && name_b->ancestor) if (!name_a->ancestor && name_b->ancestor)
return -1; return -1;
if (name_a->ancestor) if (name_a->ancestor)
return strcmp(name_a->ancestor, name_b->ancestor); return strcmp(name_a->ancestor, name_b->ancestor);
if (!name_a->ours || !name_b->ours) if (!name_a->ours || !name_b->ours)
return 0; return 0;
return strcmp(name_a->ours, name_b->ours); return strcmp(name_a->ours, name_b->ours);
} }
/** /**
* TODO: enable this when resolving case insensitive conflicts * TODO: enable this when resolving case insensitive conflicts
*/ */
#if 0
static int conflict_name_icmp(const void *a, const void *b) static int conflict_name_icmp(const void *a, const void *b)
{ {
const git_index_name_entry *name_a = a; const git_index_name_entry *name_a = a;
const git_index_name_entry *name_b = b; const git_index_name_entry *name_b = b;
if (name_a->ancestor && !name_b->ancestor) if (name_a->ancestor && !name_b->ancestor)
return 1; return 1;
if (!name_a->ancestor && name_b->ancestor) if (!name_a->ancestor && name_b->ancestor)
return -1; return -1;
if (name_a->ancestor) if (name_a->ancestor)
return strcasecmp(name_a->ancestor, name_b->ancestor); return strcasecmp(name_a->ancestor, name_b->ancestor);
if (!name_a->ours || !name_b->ours) if (!name_a->ours || !name_b->ours)
return 0; return 0;
return strcasecmp(name_a->ours, name_b->ours); return strcasecmp(name_a->ours, name_b->ours);
} }
#endif
static int reuc_srch(const void *key, const void *array_member) static int reuc_srch(const void *key, const void *array_member)
{ {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment