Fix an embarassing and rather obscure incarnation of an uninitialized
local variable use. Found by: actually using ascii2addr() :-/
This commit is contained in:
parent
3d436cd589
commit
cdd9fd70c4
@ -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