forked from premiere/premiere-libtorrent
support SIOCGIFCONF returning more interfaces than there's space in the supplied buffer
This commit is contained in:
parent
2d0464fde7
commit
36f7228001
|
@ -446,7 +446,7 @@ namespace libtorrent
|
|||
}
|
||||
ifconf ifc;
|
||||
// make sure the buffer is aligned to hold ifreq structs
|
||||
ifreq buf[30];
|
||||
ifreq buf[40];
|
||||
ifc.ifc_len = sizeof(buf);
|
||||
ifc.ifc_buf = (char*)buf;
|
||||
if (ioctl(s, SIOCGIFCONF, &ifc) < 0)
|
||||
|
@ -520,7 +520,6 @@ namespace libtorrent
|
|||
ifr += current_size;
|
||||
remaining -= current_size;
|
||||
}
|
||||
TORRENT_ASSERT(remaining == 0);
|
||||
close(s);
|
||||
|
||||
#elif TORRENT_USE_GETADAPTERSADDRESSES
|
||||
|
|
Loading…
Reference in New Issue