> 1) It seems that IcsGetInterfaceList() would fail if, for some 
> odd reason, the computer only had IPv6 interfaces. 

This would only be on Windows not MacOS, and I suspect it's impossible
to install Windows without IPv4, too much stuff is dependent on it.  

> 2) This is my function to replace LocalIpList(). 

Not sure we need to replace it, what is the advantage of using
IcsGetInterfaceList over the existing code (but see below)? 

> 3) As to the original LocalIPList() function, it seems that 
> the code at the top where it checks for ASocketFamily is not
> needed code in the "else" section handles IPv4 just fine

The 'else' stuff only works on Windows Vista and later, but not on
Windows XP which still needs GetHostByName.  While we don't officially
support Windows XP or 2000, we also don't want to deliberately break
ICS from working on them.  

But since GetHostByName is deprecated since Vista, I've changed the
code so it's now only used for Windows XP and earlier, and never for
MacOS, which should resolve your original problem.  Or are you saying
that GetAddrInfo only returns a single IP on MacOS as well?  

Testing on Windows 10, I see multiple IPv4 and IPv6 addresses using
both LocalIpList and IcsGetInterfaceList, and no duplicates.   

Angus

-- 
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to