diff options
Diffstat (limited to 'lib')
-rw-r--r-- | lib/util/util_net.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/util/util_net.c b/lib/util/util_net.c index 7d678c9b14..98eef3bd8b 100644 --- a/lib/util/util_net.c +++ b/lib/util/util_net.c @@ -405,7 +405,7 @@ bool is_zero_addr(const struct sockaddr_storage *pss) */ void zero_ip_v4(struct in_addr *ip) { - memset(ip, '\0', sizeof(struct in_addr)); + ZERO_STRUCTP(ip); } /** @@ -415,7 +415,7 @@ void in_addr_to_sockaddr_storage(struct sockaddr_storage *ss, struct in_addr ip) { struct sockaddr_in *sa = (struct sockaddr_in *)ss; - memset(ss, '\0', sizeof(*ss)); + ZERO_STRUCTP(ss); sa->sin_family = AF_INET; sa->sin_addr = ip; } |