LIBC - getifaddrs() fix
ifpa must be set to something meaningful every time it returns 0.
This commit is contained in:
parent
49246fcdd5
commit
ee99bb81b9
1 changed files with 2 additions and 0 deletions
|
@ -34,6 +34,8 @@ getifaddrs(struct ifaddrs **ifap)
|
|||
addr.sin_addr.s_addr = 0;
|
||||
netmask.sin_addr.s_addr = 0;
|
||||
|
||||
*ifap = NULL;
|
||||
|
||||
if(fd < 0) {
|
||||
char *ipd;
|
||||
|
||||
|
|
Loading…
Reference in a new issue