summaryrefslogtreecommitdiff
path: root/src/reverse-proxy.c
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2009-12-06 23:04:05 +0100
committerMichael Adam <obnox@samba.org>2009-12-07 00:22:46 +0100
commit2e6999df4aecfa2c32072e556e3e829b54a3a103 (patch)
treebe60ffe45354d5d52a0e6d29c3aa05340c1cb76e /src/reverse-proxy.c
parent3f1201c8b37280111efaf2e44d5992459eb4f4be (diff)
downloadtinyproxy-2e6999df4aecfa2c32072e556e3e829b54a3a103.tar.gz
tinyproxy-2e6999df4aecfa2c32072e556e3e829b54a3a103.zip
Add free_reversepath_list().
Michael
Diffstat (limited to 'src/reverse-proxy.c')
-rw-r--r--src/reverse-proxy.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/reverse-proxy.c b/src/reverse-proxy.c
index efafa74..fdc9098 100644
--- a/src/reverse-proxy.c
+++ b/src/reverse-proxy.c
@@ -92,6 +92,21 @@ struct reversepath *reversepath_get (char *url, struct reversepath *reverse)
return NULL;
}
+/**
+ * Free a reversepath list
+ */
+
+void free_reversepath_list (struct reversepath *reverse)
+{
+ while (reverse) {
+ struct reversepath *tmp = reverse;
+ reverse = reverse->next;
+ safefree (tmp->url);
+ safefree (tmp->path);
+ safefree (tmp);
+ }
+}
+
/*
* Rewrite the URL for reverse proxying.
*/