Andrew's git
/
gitweb.git
/ blobdiff
summary
|
log
|
commit
|
diff
|
tree
commit
grep
author
committer
pickaxe
?
re
refs.c: allow passing NULL to ref_transaction_free
[gitweb.git]
/
refs.c
diff --git
a/refs.c
b/refs.c
index 21ed46534ab81aa966860a8eaad6e499d9e2b2c3..1d6dece4266226b3a3b6f44a0afc006ac39151c4 100644
(file)
--- a/
refs.c
+++ b/
refs.c
@@
-3338,6
+3338,9
@@
void ref_transaction_free(struct ref_transaction *transaction)
{
int i;
+ if (!transaction)
+ return;
+
for (i = 0; i < transaction->nr; i++)
free(transaction->updates[i]);