Commit be6996b792cea7a7371e07fb4efc86e5216f4f40

Jacques Germishuys 2014-04-21T15:25:02

It is safe to free() a NULL pointer

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
diff --git a/src/push.c b/src/push.c
index 5c8de33..bd4d872 100644
--- a/src/push.c
+++ b/src/push.c
@@ -677,9 +677,7 @@ void git_push_status_free(push_status *status)
 	if (status == NULL)
 		return;
 
-	if (status->msg)
-		git__free(status->msg);
-
+	git__free(status->msg);
 	git__free(status->ref);
 	git__free(status);
 }