aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/service/service_manager.go
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-02-28 04:16:04 +0100
committerJason A. Donenfeld <Jason@zx2c4.com>2019-02-28 08:05:02 +0100
commit37ce1d0654ea7b69242097068ae4a75f40b3a2b2 (patch)
treee9ced18b3272875520c43f6ffea0c7e07cc8438a /service/service_manager.go
parentipc: implement event system with pipes (diff)
downloadwireguard-windows-37ce1d0654ea7b69242097068ae4a75f40b3a2b2.tar.xz
wireguard-windows-37ce1d0654ea7b69242097068ae4a75f40b3a2b2.zip
manager: wire up tunnels changed notifier
Diffstat (limited to 'service/service_manager.go')
-rw-r--r--service/service_manager.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/service/service_manager.go b/service/service_manager.go
index eb28e833..6b4a9b90 100644
--- a/service/service_manager.go
+++ b/service/service_manager.go
@@ -9,6 +9,7 @@ import (
"golang.org/x/sys/windows"
"golang.org/x/sys/windows/svc"
"golang.org/x/sys/windows/svc/eventlog"
+ "golang.zx2c4.com/wireguard/windows/conf"
"log"
"os"
"strconv"
@@ -128,6 +129,8 @@ func (service *managerService) Execute(args []string, r <-chan svc.ChangeRequest
return
}
+ conf.RegisterStoreChangeCallback(IPCServerNotifyTunnelsChange)
+
procs := make(map[uint32]*os.Process)
procsLock := sync.Mutex{}
var startProcess func(session uint32)