Commit d9eae98b571cb1bac58904541c5bc5669e33f57f

Etienne Samson 2018-10-24T01:30:12

refs: assert that we're passed valid refs when renaming CID 1382962

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/src/refs.c b/src/refs.c
index 50afb26..85599da 100644
--- a/src/refs.c
+++ b/src/refs.c
@@ -709,6 +709,8 @@ int git_reference_rename(
 	git_signature *who;
 	int error;
 
+	assert(out && ref);
+
 	if ((error = git_reference__log_signature(&who, ref->db->repo)) < 0)
 		return error;