mirror of
https://github.com/kanjitalk755/macemu.git
synced 2024-12-24 10:32:32 +00:00
Support version 0901 TAP devices in Windows
This commit is contained in:
parent
6bb9d00184
commit
517e2aa7ab
@ -400,7 +400,7 @@ const TCHAR *ether_guid_to_name(const TCHAR *guid)
|
|||||||
|
|
||||||
#define ADAPTER_KEY TEXT("SYSTEM\\CurrentControlSet\\Control\\Class\\{4D36E972-E325-11CE-BFC1-08002BE10318}")
|
#define ADAPTER_KEY TEXT("SYSTEM\\CurrentControlSet\\Control\\Class\\{4D36E972-E325-11CE-BFC1-08002BE10318}")
|
||||||
|
|
||||||
#define TAP_COMPONENT_ID TEXT("tap0801")
|
const _TCHAR * tap_component_ids[] = { TEXT("tap0801"), TEXT("tap0901"), 0 };
|
||||||
|
|
||||||
const TCHAR *ether_tap_devices(void)
|
const TCHAR *ether_tap_devices(void)
|
||||||
{
|
{
|
||||||
@ -475,8 +475,13 @@ const TCHAR *ether_tap_devices(void)
|
|||||||
&len);
|
&len);
|
||||||
|
|
||||||
if (status == ERROR_SUCCESS && data_type == REG_SZ) {
|
if (status == ERROR_SUCCESS && data_type == REG_SZ) {
|
||||||
if (!_tcscmp (component_id, TAP_COMPONENT_ID))
|
const _TCHAR * * cur_tap_component_id;
|
||||||
|
for (cur_tap_component_id = tap_component_ids; *cur_tap_component_id != NULL; cur_tap_component_id++) {
|
||||||
|
if (!_tcscmp(component_id, *cur_tap_component_id)) {
|
||||||
devices.push_back(net_cfg_instance_id);
|
devices.push_back(net_cfg_instance_id);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RegCloseKey (unit_key);
|
RegCloseKey (unit_key);
|
||||||
|
Loading…
Reference in New Issue
Block a user