From eba1bc411b9c5af9e6d5aa9f32b5ecf623d1f76a Mon Sep 17 00:00:00 2001 From: Toomas Soome Date: Wed, 1 Aug 2018 11:40:52 +0000 Subject: [PATCH] libsa: pointer differs in signedness A small cleanup, fix the argument type and while there, replace (char *)0 with NULL. --- stand/libsa/net.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stand/libsa/net.c b/stand/libsa/net.c index 31ff5e3ce36..77094d9ceb3 100644 --- a/stand/libsa/net.c +++ b/stand/libsa/net.c @@ -267,7 +267,7 @@ intoa(n_long addr) } static char * -number(char *s, int *n) +number(char *s, n_long *n) { for (*n = 0; isdigit(*s); s++) *n = (*n * 10) + *s - '0'; @@ -280,7 +280,7 @@ ip_convertaddr(char *p) #define IP_ANYADDR 0 n_long addr = 0, n; - if (p == (char *)0 || *p == '\0') + if (p == NULL || *p == '\0') return IP_ANYADDR; p = number(p, &n); addr |= (n << 24) & 0xff000000;