Add the LocalDiscoveryAddress option.
[tinc] / src / subnet.c
index 4b6c068..bf4300e 100644 (file)
@@ -1,6 +1,6 @@
 /*
     subnet.c -- handle subnet lookups and lists
-    Copyright (C) 2000-2012 Guus Sliepen <guus@tinc-vpn.org>,
+    Copyright (C) 2000-2013 Guus Sliepen <guus@tinc-vpn.org>,
                   2000-2005 Ivo Timmermans
 
     This program is free software; you can redistribute it and/or modify
@@ -25,6 +25,7 @@
 #include "device.h"
 #include "hash.h"
 #include "logger.h"
+#include "names.h"
 #include "net.h"
 #include "netutl.h"
 #include "node.h"
@@ -78,7 +79,7 @@ void free_subnet_tree(splay_tree_t *subnet_tree) {
 /* Allocating and freeing space for subnets */
 
 subnet_t *new_subnet(void) {
-       return xmalloc_and_zero(sizeof(subnet_t));
+       return xzalloc(sizeof(subnet_t));
 }
 
 void free_subnet(subnet_t *subnet) {