vector: avoid double asserting index_initialize() calls assert() for arguments on its own. No need to call it twice. Signed-off-by: Kirill A. Shutemov <kirill@shutemov.name>
diff --git a/src/index.c b/src/index.c
index 9883287..6f874d5 100644
--- a/src/index.c
+++ b/src/index.c
@@ -178,7 +178,6 @@ static int index_initialize(git_index **index_out, git_repository *owner, const
int git_index_open(git_index **index_out, const char *index_path)
{
- assert(index_out && index_path);
return index_initialize(index_out, NULL, index_path);
}
@@ -187,8 +186,6 @@ int git_index_open(git_index **index_out, const char *index_path)
*/
int git_repository_index(git_index **index_out, git_repository *repo)
{
- assert(index_out && repo);
-
if (repo->is_bare)
return git__throw(GIT_EBAREINDEX, "Failed to open index. Repository is bare");