Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/libgit2.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornulltoken <emeric.fermas@gmail.com>2012-07-20 18:41:41 +0400
committernulltoken <emeric.fermas@gmail.com>2012-07-24 18:09:50 +0400
commit786a17cd282cf81c76c45a8e62f2a1003235a673 (patch)
tree7cbf2731f86460ef20a1162f747b4be092add209 /src/branch.c
parentef4d795ec5f8cd39de72cfbc75565236205833a4 (diff)
branch: enforce git_branch_delete() parameter checking
Diffstat (limited to 'src/branch.c')
-rw-r--r--src/branch.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/branch.c b/src/branch.c
index d0ebb2dc3..d11eca8da 100644
--- a/src/branch.c
+++ b/src/branch.c
@@ -110,6 +110,7 @@ int git_branch_delete(git_repository *repo, const char *branch_name, git_branch_
git_reference *head = NULL;
int error;
+ assert(repo && branch_name);
assert((branch_type == GIT_BRANCH_LOCAL) || (branch_type == GIT_BRANCH_REMOTE));
if ((error = retrieve_branch_reference(&branch, repo, branch_name, branch_type == GIT_BRANCH_REMOTE)) < 0)