X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;f=src%2Fnode.c;h=dbc5a7eb32152135c1357115814b50fc51e02844;hb=434e57ae5ee79b3d990c4d75358047bad641998b;hp=dee7aadf98f0baf2194b5fc352555ba22a7461c7;hpb=f4010694b3b16453e5e6298c208910264e326978;p=meshlink diff --git a/src/node.c b/src/node.c index dee7aadf..dbc5a7eb 100644 --- a/src/node.c +++ b/src/node.c @@ -126,7 +126,7 @@ void node_del(node_t *n) { } node_t *lookup_node(char *name) { - node_t n = {0}; + node_t n = {NULL}; n.name = name; @@ -134,7 +134,7 @@ node_t *lookup_node(char *name) { } node_t *lookup_node_udp(const sockaddr_t *sa) { - node_t n = {0}; + node_t n = {NULL}; n.address = *sa; n.name = NULL; @@ -160,7 +160,7 @@ void update_node_udp(node_t *n, const sockaddr_t *sa) { logger(LOG_DEBUG, "UDP address of %s set to %s", n->name, n->hostname); } else { memset(&n->address, 0, sizeof n->address); - n->hostname = 0; + n->hostname = NULL; ifdebug(PROTOCOL) logger(LOG_DEBUG, "UDP address of %s cleared", n->name); } }