Merge branch 'rs/apply-lose-prefix-length' into next
[gitweb.git] / transport.c
index 9bfcf870f9078f75349bd3b4976c71bbf5c49ebf..d75ff0514d8d4dd05da1d618ddf2602e5a4f26a9 100644 (file)
@@ -1,4 +1,5 @@
 #include "cache.h"
+#include "config.h"
 #include "transport.h"
 #include "run-command.h"
 #include "pkt-line.h"
@@ -1145,8 +1146,7 @@ void transport_unlock_pack(struct transport *transport)
 {
        if (transport->pack_lockfile) {
                unlink_or_warn(transport->pack_lockfile);
-               free(transport->pack_lockfile);
-               transport->pack_lockfile = NULL;
+               FREE_AND_NULL(transport->pack_lockfile);
        }
 }