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
a912ea3f
Commit
a912ea3f
authored
Apr 03, 2012
by
schu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
tests-clar/object: remove unused helper print_tree()
Signed-off-by: schu <schu-github@schulog.org>
parent
daa22dee
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
30 deletions
+0
-30
tests-clar/object/tree/write.c
+0
-30
No files found.
tests-clar/object/tree/write.c
View file @
a912ea3f
...
@@ -9,36 +9,6 @@ static const char *third_tree = "eb86d8b81d6adbd5290a935d6c9976882de98488";
...
@@ -9,36 +9,6 @@ static const char *third_tree = "eb86d8b81d6adbd5290a935d6c9976882de98488";
static
git_repository
*
g_repo
;
static
git_repository
*
g_repo
;
// Helpers
static
int
print_tree
(
git_repository
*
repo
,
const
git_oid
*
tree_oid
,
int
depth
)
{
static
const
char
*
indent
=
" "
;
git_tree
*
tree
;
unsigned
int
i
;
if
(
git_tree_lookup
(
&
tree
,
repo
,
tree_oid
)
<
GIT_SUCCESS
)
return
GIT_ERROR
;
for
(
i
=
0
;
i
<
git_tree_entrycount
(
tree
);
++
i
)
{
const
git_tree_entry
*
entry
=
git_tree_entry_byindex
(
tree
,
i
);
char
entry_oid
[
40
];
git_oid_fmt
(
entry_oid
,
&
entry
->
oid
);
printf
(
"%.*s%o [%.*s] %s
\n
"
,
depth
*
2
,
indent
,
entry
->
attr
,
40
,
entry_oid
,
entry
->
filename
);
if
(
entry
->
attr
==
S_IFDIR
)
{
if
(
print_tree
(
repo
,
&
entry
->
oid
,
depth
+
1
)
<
GIT_SUCCESS
)
{
git_tree_free
(
tree
);
return
GIT_ERROR
;
}
}
}
git_tree_free
(
tree
);
return
GIT_SUCCESS
;
}
// Fixture setup and teardown
// Fixture setup and teardown
void
test_object_tree_write__initialize
(
void
)
void
test_object_tree_write__initialize
(
void
)
{
{
...
...
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