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
718eb4b8
Commit
718eb4b8
authored
Nov 07, 2011
by
Carlos Martín Nieto
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reword packed-refs error messages so they're easier to track down
Signed-off-by: Carlos Martín Nieto <carlos@cmartin.tk>
parent
0c49ec2d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
src/refs.c
+4
-4
No files found.
src/refs.c
View file @
718eb4b8
...
...
@@ -757,7 +757,7 @@ static int packed_write(git_repository *repo)
total_refs
=
repo
->
references
.
packfile
->
key_count
;
if
((
error
=
git_vector_init
(
&
packing_list
,
total_refs
,
packed_sort
))
<
GIT_SUCCESS
)
return
git__rethrow
(
error
,
"Failed to
write packed reference
"
);
return
git__rethrow
(
error
,
"Failed to
init packed refernces list
"
);
/* Load all the packfile into a vector */
{
...
...
@@ -776,14 +776,14 @@ static int packed_write(git_repository *repo)
/* Now we can open the file! */
git_path_join
(
pack_file_path
,
repo
->
path_repository
,
GIT_PACKEDREFS_FILE
);
if
((
error
=
git_filebuf_open
(
&
pack_file
,
pack_file_path
,
0
))
<
GIT_SUCCESS
)
return
git__rethrow
(
error
,
"Failed to write
packed referenc
e"
);
return
git__rethrow
(
error
,
"Failed to write
open packed references fil
e"
);
/* Packfiles have a header... apparently
* This is in fact not required, but we might as well print it
* just for kicks */
if
((
error
=
git_filebuf_printf
(
&
pack_file
,
"%s
\n
"
,
GIT_PACKEDREFS_HEADER
))
<
GIT_SUCCESS
)
return
git__rethrow
(
error
,
"Failed to write packed reference"
);
return
git__rethrow
(
error
,
"Failed to write packed reference
s file header
"
);
for
(
i
=
0
;
i
<
packing_list
.
length
;
++
i
)
{
struct
packref
*
ref
=
(
struct
packref
*
)
git_vector_get
(
&
packing_list
,
i
);
...
...
@@ -821,7 +821,7 @@ cleanup:
return
error
==
GIT_SUCCESS
?
GIT_SUCCESS
:
git__rethrow
(
error
,
"Failed to write packed reference"
);
git__rethrow
(
error
,
"Failed to write packed reference
s file
"
);
}
static
int
_reference_available_cb
(
const
char
*
ref
,
void
*
data
)
...
...
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