From 1c92b48415e7f68cce859b4adf95c5d1ce5df9e9 Mon Sep 17 00:00:00 2001 From: Simon Rozman Date: Fri, 10 May 2019 17:37:03 +0200 Subject: wintun: registry: replace REG_NOTIFY with NOTIFY Signed-off-by: Simon Rozman --- tun/wintun/wintun_windows.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'tun/wintun/wintun_windows.go') diff --git a/tun/wintun/wintun_windows.go b/tun/wintun/wintun_windows.go index 8163f94..7327f98 100644 --- a/tun/wintun/wintun_windows.go +++ b/tun/wintun/wintun_windows.go @@ -299,7 +299,7 @@ func CreateInterface(description string, hwndParent uintptr) (*Wintun, bool, err if i != 0 { time.Sleep(pollTimeout) } - key, err = devInfoList.OpenDevRegKey(deviceData, setupapi.DICS_FLAG_GLOBAL, 0, setupapi.DIREG_DRV, registry.QUERY_VALUE|registryEx.KEY_NOTIFY) + key, err = devInfoList.OpenDevRegKey(deviceData, setupapi.DICS_FLAG_GLOBAL, 0, setupapi.DIREG_DRV, registry.QUERY_VALUE|registry.NOTIFY) if err == nil { break } @@ -326,7 +326,7 @@ func CreateInterface(description string, hwndParent uintptr) (*Wintun, bool, err key, err = registryEx.OpenKeyWait( registry.LOCAL_MACHINE, wintun.GetNetRegKeyName(), - registry.QUERY_VALUE|registryEx.KEY_NOTIFY, + registry.QUERY_VALUE|registry.NOTIFY, waitForRegistryTimeout) if err == nil { _, err = registryEx.GetStringValueWait(key, "Name", waitForRegistryTimeout) @@ -338,7 +338,7 @@ func CreateInterface(description string, hwndParent uintptr) (*Wintun, bool, err // Wait for TCP/IP adapter registry key to emerge and populate. key, err = registryEx.OpenKeyWait( registry.LOCAL_MACHINE, - wintun.GetTcpipAdapterRegKeyName(), registry.QUERY_VALUE|registryEx.KEY_NOTIFY, + wintun.GetTcpipAdapterRegKeyName(), registry.QUERY_VALUE|registry.NOTIFY, waitForRegistryTimeout) if err == nil { _, err = registryEx.GetFirstStringValueWait(key, "IpConfig", waitForRegistryTimeout) -- cgit v1.2.3-59-g8ed1b