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
6623f5c9
Commit
6623f5c9
authored
May 23, 2011
by
Vicent Marti
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
object: Reword errors
parent
75eb97fe
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
src/object.c
+3
-3
No files found.
src/object.c
View file @
6623f5c9
...
...
@@ -86,7 +86,7 @@ static int create_object(git_object **object_out, git_otype type)
break
;
default:
return
git__throw
(
GIT_EINVALIDTYPE
,
"
Failed to create object. G
iven type is invalid"
);
return
git__throw
(
GIT_EINVALIDTYPE
,
"
The g
iven type is invalid"
);
}
object
->
type
=
type
;
...
...
@@ -106,7 +106,7 @@ int git_object_lookup(git_object **object_out, git_repository *repo, const git_o
object
=
git_cache_get
(
&
repo
->
objects
,
id
);
if
(
object
!=
NULL
)
{
if
(
type
!=
GIT_OBJ_ANY
&&
type
!=
object
->
type
)
return
git__throw
(
GIT_EINVALIDTYPE
,
"Failed to lookup object.
Given type does not match found type
"
);
return
git__throw
(
GIT_EINVALIDTYPE
,
"Failed to lookup object.
The given type does not match the type on the ODB
"
);
*
object_out
=
object
;
return
GIT_SUCCESS
;
...
...
@@ -118,7 +118,7 @@ int git_object_lookup(git_object **object_out, git_repository *repo, const git_o
if
(
type
!=
GIT_OBJ_ANY
&&
type
!=
odb_obj
->
raw
.
type
)
{
git_odb_object_close
(
odb_obj
);
return
git__throw
(
GIT_EINVALIDTYPE
,
"Failed to lookup object.
Given type does not match found type
"
);
return
git__throw
(
GIT_EINVALIDTYPE
,
"Failed to lookup object.
The given type does not match the type on the ODB
"
);
}
type
=
odb_obj
->
raw
.
type
;
...
...
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