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
a667ca82
Commit
a667ca82
authored
Nov 05, 2013
by
Arthur Schreiber
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Change the git_branch_iterator_new and git_branch_next definitions to use git_branch_t.
parent
aad5403f
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
7 deletions
+7
-7
include/git2/branch.h
+2
-2
src/branch.c
+2
-2
tests-clar/online/push.c
+1
-1
tests-clar/refs/branches/iterator.c
+2
-2
No files found.
include/git2/branch.h
View file @
a667ca82
...
...
@@ -83,7 +83,7 @@ typedef struct git_branch_iterator git_branch_iterator;
GIT_EXTERN
(
int
)
git_branch_iterator_new
(
git_branch_iterator
**
out
,
git_repository
*
repo
,
unsigned
in
t
list_flags
);
git_branch_
t
list_flags
);
/**
* Retrieve the next branch from the iterator
...
...
@@ -93,7 +93,7 @@ GIT_EXTERN(int) git_branch_iterator_new(
* @param iter the branch iterator
* @return 0 on success, GIT_ITEROVER if there are no more branches or an error code.
*/
GIT_EXTERN
(
int
)
git_branch_next
(
git_reference
**
out
,
unsigned
in
t
*
out_type
,
git_branch_iterator
*
iter
);
GIT_EXTERN
(
int
)
git_branch_next
(
git_reference
**
out
,
git_branch_
t
*
out_type
,
git_branch_iterator
*
iter
);
/**
* Free a branch iterator
...
...
src/branch.c
View file @
a667ca82
...
...
@@ -129,7 +129,7 @@ typedef struct {
unsigned
int
flags
;
}
branch_iter
;
int
git_branch_next
(
git_reference
**
out
,
unsigned
in
t
*
out_type
,
git_branch_iterator
*
_iter
)
int
git_branch_next
(
git_reference
**
out
,
git_branch_
t
*
out_type
,
git_branch_iterator
*
_iter
)
{
branch_iter
*
iter
=
(
branch_iter
*
)
_iter
;
git_reference
*
ref
;
...
...
@@ -159,7 +159,7 @@ int git_branch_next(git_reference **out, unsigned int *out_type, git_branch_iter
int
git_branch_iterator_new
(
git_branch_iterator
**
out
,
git_repository
*
repo
,
unsigned
in
t
list_flags
)
git_branch_
t
list_flags
)
{
branch_iter
*
iter
;
...
...
tests-clar/online/push.c
View file @
a667ca82
...
...
@@ -182,7 +182,7 @@ static void verify_tracking_branches(git_remote *remote, expected_ref expected_r
char
*
actual_ref
;
git_oid
oid
;
int
failed
=
0
,
error
;
unsigned
in
t
branch_type
;
git_branch_
t
branch_type
;
git_reference
*
ref
;
/* Get current remote branches */
...
...
tests-clar/refs/branches/iterator.c
View file @
a667ca82
...
...
@@ -33,7 +33,7 @@ static void assert_retrieval(unsigned int flags, unsigned int expected_count)
git_branch_iterator
*
iter
;
git_reference
*
ref
;
int
count
=
0
,
error
;
unsigned
in
t
type
;
git_branch_
t
type
;
cl_git_pass
(
git_branch_iterator_new
(
&
iter
,
repo
,
flags
));
while
((
error
=
git_branch_next
(
&
ref
,
&
type
,
iter
))
==
0
)
{
...
...
@@ -83,7 +83,7 @@ static void assert_branch_has_been_found(struct expectations *findings, const ch
static
void
contains_branches
(
struct
expectations
exp
[],
git_branch_iterator
*
iter
)
{
git_reference
*
ref
;
unsigned
in
t
type
;
git_branch_
t
type
;
int
error
,
pos
=
0
;
while
((
error
=
git_branch_next
(
&
ref
,
&
type
,
iter
))
==
0
)
{
...
...
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