Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
git2
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
lvzhengyang
git2
Commits
81b7dec4
Commit
81b7dec4
authored
May 02, 2013
by
Russell Belfer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix some compile warnings and trailing whitespace
parent
d82d66c9
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
10 deletions
+12
-10
src/index.c
+12
-10
No files found.
src/index.c
View file @
81b7dec4
...
...
@@ -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_b
=
b
;
if
(
name_a
->
ancestor
&&
!
name_b
->
ancestor
)
return
1
;
if
(
!
name_a
->
ancestor
&&
name_b
->
ancestor
)
return
-
1
;
if
(
name_a
->
ancestor
)
return
strcmp
(
name_a
->
ancestor
,
name_b
->
ancestor
);
if
(
!
name_a
->
ours
||
!
name_b
->
ours
)
return
0
;
return
strcmp
(
name_a
->
ours
,
name_b
->
ours
);
}
/**
* TODO: enable this when resolving case insensitive conflicts
*/
#if 0
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_b = b;
if (name_a->ancestor && !name_b->ancestor)
return 1;
if (!name_a->ancestor && name_b->ancestor)
return -1;
if (name_a->ancestor)
return strcasecmp(name_a->ancestor, name_b->ancestor);
if (!name_a->ours || !name_b->ours)
return 0;
return strcasecmp(name_a->ours, name_b->ours);
}
#endif
static
int
reuc_srch
(
const
void
*
key
,
const
void
*
array_member
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment