BBA: Fix TAP detection
This commit is contained in:
parent
8d237eb102
commit
edb843415d
|
@ -66,11 +66,16 @@ bool IsTAPDevice(const TCHAR* guid)
|
||||||
|
|
||||||
if (status == ERROR_SUCCESS && data_type == REG_SZ)
|
if (status == ERROR_SUCCESS && data_type == REG_SZ)
|
||||||
{
|
{
|
||||||
if (!_tcscmp(component_id, TAP_COMPONENT_ID) && !_tcscmp(net_cfg_instance_id, guid))
|
TCHAR* const component_id_sub = _tcsstr(component_id, TAP_COMPONENT_ID);
|
||||||
|
|
||||||
|
if (component_id_sub)
|
||||||
{
|
{
|
||||||
RegCloseKey(unit_key);
|
if (!_tcscmp(component_id_sub, TAP_COMPONENT_ID) && !_tcscmp(net_cfg_instance_id, guid))
|
||||||
RegCloseKey(netcard_key);
|
{
|
||||||
return true;
|
RegCloseKey(unit_key);
|
||||||
|
RegCloseKey(netcard_key);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue