Fix an embarassing and rather obscure incarnation of an uninitialized
local variable use. Found by: actually using ascii2addr() :-/
This commit is contained in:
parent
48b07dc365
commit
20ea94ba7d
@ -51,7 +51,7 @@ ascii2addr(af, ascii, result)
|
||||
switch(af) {
|
||||
case AF_INET:
|
||||
ina = result;
|
||||
strncat(strbuf, ascii, (sizeof strbuf)-1);
|
||||
strncpy(strbuf, ascii, (sizeof strbuf)-1);
|
||||
if (inet_aton(strbuf, ina))
|
||||
return sizeof(struct in_addr);
|
||||
errno = EINVAL;
|
||||
|
Loading…
Reference in New Issue
Block a user