Add allocation and freeing functions for struct refs
[gitweb.git] / remote.h
index 01dbcef67048d2fe068a2ab348013cc3055b5195..080b7dab99348952d8d89fef428a317b1c4bd055 100644 (file)
--- a/remote.h
+++ b/remote.h
@@ -30,6 +30,13 @@ struct refspec {
        char *dst;
 };
 
+struct ref *alloc_ref(unsigned namelen);
+
+/*
+ * Frees the entire list and peers of elements.
+ */
+void free_refs(struct ref *ref);
+
 int match_refs(struct ref *src, struct ref *dst, struct ref ***dst_tail,
               int nr_refspec, char **refspec, int all);