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
11634346
Commit
11634346
authored
Jun 22, 2012
by
nulltoken
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
revwalk: make git_revwalk_(push|hide)_glob() leverage git_reference_foreach_glob()
parent
527ed554
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
8 deletions
+3
-8
src/revwalk.c
+3
-8
No files found.
src/revwalk.c
View file @
11634346
...
...
@@ -540,7 +540,6 @@ static int push_ref(git_revwalk *walk, const char *refname, int hide)
struct
push_cb_data
{
git_revwalk
*
walk
;
const
char
*
glob
;
int
hide
;
};
...
...
@@ -548,10 +547,7 @@ static int push_glob_cb(const char *refname, void *data_)
{
struct
push_cb_data
*
data
=
(
struct
push_cb_data
*
)
data_
;
if
(
!
p_fnmatch
(
data
->
glob
,
refname
,
0
))
return
push_ref
(
data
->
walk
,
refname
,
data
->
hide
);
return
0
;
return
push_ref
(
data
->
walk
,
refname
,
data
->
hide
);
}
static
int
push_glob
(
git_revwalk
*
walk
,
const
char
*
glob
,
int
hide
)
...
...
@@ -584,11 +580,10 @@ static int push_glob(git_revwalk *walk, const char *glob, int hide)
goto
on_error
;
data
.
walk
=
walk
;
data
.
glob
=
git_buf_cstr
(
&
buf
);
data
.
hide
=
hide
;
if
(
git_reference_foreach
(
walk
->
repo
,
GIT_REF_LISTALL
,
push_glob_cb
,
&
data
)
<
0
)
if
(
git_reference_foreach
_glob
(
walk
->
repo
,
git_buf_cstr
(
&
buf
)
,
GIT_REF_LISTALL
,
push_glob_cb
,
&
data
)
<
0
)
goto
on_error
;
regfree
(
&
preg
);
...
...
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