Merge pull request #102937 from gy95/service

remove windows service not used global variable
This commit is contained in:
Kubernetes Prow Robot
2021-09-15 21:41:45 -07:00
committed by GitHub

View File

@@ -30,10 +30,6 @@ import (
"golang.org/x/sys/windows/svc"
)
var (
service *handler
)
type handler struct {
tosvc chan bool
fromsvc chan error
@@ -48,7 +44,6 @@ func InitService(serviceName string) error {
fromsvc: make(chan error),
}
service = h
var err error
go func() {
err = svc.Run(serviceName, h)