mirror of
https://github.com/libgit2/libgit2.git
synced 2026-06-22 06:26:26 +00:00
Add assert
Description: In an older version of libgit2 in git_object_lookup_prefix was a check that repo is valid, but now there is repo->oid_type in the git_object_lookup and must be checked as well
This commit is contained in:
@@ -281,6 +281,7 @@ int git_object_lookup_prefix(
|
||||
}
|
||||
|
||||
int git_object_lookup(git_object **object_out, git_repository *repo, const git_oid *id, git_object_t type) {
|
||||
GIT_ASSERT_ARG(repo);
|
||||
return git_object_lookup_prefix(object_out,
|
||||
repo, id, git_oid_hexsize(repo->oid_type), type);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user