aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/service
diff options
context:
space:
mode:
authorJason A. Donenfeld <Jason@zx2c4.com>2019-05-07 08:15:39 +0200
committerJason A. Donenfeld <Jason@zx2c4.com>2019-05-07 08:15:39 +0200
commit6274fc5f5ed971a81ee6ff30c0ed72b58ac4ce66 (patch)
tree9a6ec44e42f8eb9e9bd2bca00db6ce2a80f249ca /service
parentinstaller: fix tag style (diff)
downloadwireguard-windows-6274fc5f5ed971a81ee6ff30c0ed72b58ac4ce66.tar.xz
wireguard-windows-6274fc5f5ed971a81ee6ff30c0ed72b58ac4ce66.zip
ringlogger: export R/O handle for UI process
Diffstat (limited to 'service')
-rw-r--r--service/securityapi.go2
-rw-r--r--service/service_manager.go3
2 files changed, 3 insertions, 2 deletions
diff --git a/service/securityapi.go b/service/securityapi.go
index 6c5f7844..6373fd7c 100644
--- a/service/securityapi.go
+++ b/service/securityapi.go
@@ -154,4 +154,4 @@ func getCurrentSecurityAttributes() (*syscall.SecurityAttributes, error) {
return nil, err
}
return securityAttributes, nil
-} \ No newline at end of file
+}
diff --git a/service/service_manager.go b/service/service_manager.go
index e8818ae4..e2ccf4c9 100644
--- a/service/service_manager.go
+++ b/service/service_manager.go
@@ -143,7 +143,7 @@ func (service *managerService) Execute(args []string, r <-chan svc.ChangeRequest
log.Printf("Unable to listen on IPC pipes: %v", err)
return
}
- theirLogMapping, err := ringlogger.Global.ExportInheritableMappingHandleStr()
+ theirLogMapping, theirLogMappingHandle, err := ringlogger.Global.ExportInheritableMappingHandleStr()
if err != nil {
log.Printf("Unable to export inheritable mapping handle for logging: %v", err)
return
@@ -173,6 +173,7 @@ func (service *managerService) Execute(args []string, r <-chan svc.ChangeRequest
theirReader.Close()
theirWriter.Close()
theirEvents.Close()
+ windows.Close(theirLogMappingHandle)
runtime.UnlockOSThread()
if err != nil {
log.Printf("Unable to start manager UI process: %v", err)