Unfortunately VPN interfaces I am observing here don't expose any definite type in ifr_hwaddr.sa_data (having ARPHRD_NONE). But the flags from SIOCGIFFLAGS have IFF_POINTOPOINT for such interfaces, so it is probably nothing wrong in guessing the iface type as PPP if the flag is set.
Fixes Creativerse hanging on creating local game when there is a VPN interface.
-- v2: nsiproxy.sys: Detect PPP interface type from flags on Linux.
From: Paul Gofman pgofman@codeweavers.com
VPN interfaces often have ARPHRD_NONE in ifr_hwaddr.sa_data but IFF_POINTOPOINT flag set. --- dlls/nsiproxy.sys/ndis.c | 3 +++ 1 file changed, 3 insertions(+)
diff --git a/dlls/nsiproxy.sys/ndis.c b/dlls/nsiproxy.sys/ndis.c index c34630d8aec..1fc66c3611b 100644 --- a/dlls/nsiproxy.sys/ndis.c +++ b/dlls/nsiproxy.sys/ndis.c @@ -170,6 +170,9 @@ static NTSTATUS if_get_physical( const char *name, UINT *type, IF_PHYSICAL_ADDRE break; }
+ if (*type == MIB_IF_TYPE_OTHER && !ioctl( fd, SIOCGIFFLAGS, &ifr ) && ifr.ifr_flags & IFF_POINTOPOINT) + *type = MIB_IF_TYPE_PPP; + err: close( fd ); return ret;
v2: - fix spurious blank line deletion; - remove traces; - add a comment to commit.
This merge request was approved by Huw Davies.