upnp: do not throw when getting network interfaces.

This commit is contained in:
Christopher Jeffrey 2017-03-02 11:58:26 -08:00
parent 525e6f21b7
commit 0791bad973
No known key found for this signature in database
GPG Key ID: 8962AB9DE6666BBD

View File

@ -323,7 +323,11 @@ UPNP.getInterfaceIP = function getInterfaceIP(name, family) {
if (type !== family)
continue;
ip = IP.toBuffer(details.address);
try {
ip = IP.toBuffer(details.address);
} catch (e) {
continue;
}
if (IP.isLocal(ip))
continue;