aboutsummaryrefslogtreecommitdiff
path: root/src/or/policies.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2017-11-21 09:37:47 -0500
committerNick Mathewson <nickm@torproject.org>2017-12-08 14:47:19 -0500
commit176ad729d9b1ddeccdb3e721b5ab1bf64646223f (patch)
treebe4ff3e62b459859c7c87bf663a37e3806eac8f9 /src/or/policies.h
parent0792cc107ef588b9f9fa27165b73e19fbf07e92b (diff)
downloadtor-176ad729d9b1ddeccdb3e721b5ab1bf64646223f.tar.gz
tor-176ad729d9b1ddeccdb3e721b5ab1bf64646223f.zip
Change the free macro convention in the rest of src/or/*.h
Diffstat (limited to 'src/or/policies.h')
-rw-r--r--src/or/policies.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/or/policies.h b/src/or/policies.h
index cd97ee7f59..062f330183 100644
--- a/src/or/policies.h
+++ b/src/or/policies.h
@@ -115,15 +115,18 @@ int getinfo_helper_policies(control_connection_t *conn,
int policy_write_item(char *buf, size_t buflen, const addr_policy_t *item,
int format_for_desc);
-void addr_policy_list_free(smartlist_t *p);
-void addr_policy_free(addr_policy_t *p);
+void addr_policy_list_free_(smartlist_t *p);
+#define addr_policy_list_free(lst) FREE_AND_NULL(addr_policy_list, (lst))
+void addr_policy_free_(addr_policy_t *p);
+#define addr_policy_free(p) FREE_AND_NULL(addr_policy, (p))
void policies_free_all(void);
char *policy_summarize(smartlist_t *policy, sa_family_t family);
short_policy_t *parse_short_policy(const char *summary);
char *write_short_policy(const short_policy_t *policy);
-void short_policy_free(short_policy_t *policy);
+void short_policy_free_(short_policy_t *policy);
+#define short_policy_free(p) FREE_AND_NULL(short_policy, (p))
int short_policy_is_reject_star(const short_policy_t *policy);
addr_policy_result_t compare_tor_addr_to_short_policy(
const tor_addr_t *addr, uint16_t port,