diff options
author | Simon Rozman <simon@rozman.si> | 2020-10-29 12:04:34 +0100 |
---|---|---|
committer | Simon Rozman <simon@rozman.si> | 2020-10-31 10:41:46 +0100 |
commit | 4a575d210a34384787d4936dfb96d6b8cb2ea48c (patch) | |
tree | 0cde3fe255d641812a1af9f741c23312b03bfe48 /api/adapter.c | |
parent | api: depretiate WintunIsPacketAvailable() (diff) | |
download | wintun-4a575d210a34384787d4936dfb96d6b8cb2ea48c.tar.xz wintun-4a575d210a34384787d4936dfb96d6b8cb2ea48c.zip |
api: fallback to hard-coded version
Windows 7 doesn't have DriverMajorVersion and DriverMinorVersion
registry values yet.
Signed-off-by: Simon Rozman <simon@rozman.si>
Diffstat (limited to 'api/adapter.c')
-rw-r--r-- | api/adapter.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/api/adapter.c b/api/adapter.c index 0035e8d..63e1e76 100644 --- a/api/adapter.c +++ b/api/adapter.c @@ -541,7 +541,7 @@ CreateAdapterData( HeapFree(ModuleHeap, 0, ValueStr); /* Read the NetLuidIndex value. */ - Result = RegistryQueryDWORD(Key, L"NetLuidIndex", &(*Adapter)->LuidIndex); + Result = RegistryQueryDWORD(Key, L"NetLuidIndex", &(*Adapter)->LuidIndex, TRUE); if (Result != ERROR_SUCCESS) { LOG(WINTUN_LOG_ERR, L"Failed to query NetLuidIndex value"); @@ -549,7 +549,7 @@ CreateAdapterData( } /* Read the NetLuidIndex value. */ - Result = RegistryQueryDWORD(Key, L"*IfType", &(*Adapter)->IfType); + Result = RegistryQueryDWORD(Key, L"*IfType", &(*Adapter)->IfType, TRUE); if (Result != ERROR_SUCCESS) { LOG(WINTUN_LOG_ERR, L"Failed to query *IfType value"); |