diff options
author | Lunny Xiao <xiaolunwen@gmail.com> | 2021-01-06 09:38:00 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-01-06 09:38:00 +0800 |
commit | a1c9e8f266cb2809200dce1618da33314cc25082 (patch) | |
tree | abb0fbe7f94bd767e4ffef8f1449ed35427a8286 /modules/graceful/manager_windows.go | |
parent | 4ef5f17a7e1fefb96d4c6d8ff32ead01248bad5a (diff) | |
download | gitea-a1c9e8f266cb2809200dce1618da33314cc25082.tar.gz gitea-a1c9e8f266cb2809200dce1618da33314cc25082.zip |
Fix windows build error (#14263)
* fix build
* take flash error message back and fix more windows lint error
* performance optimization
* own step to check lint for windows
Co-authored-by: 6543 <6543@obermui.de>
Diffstat (limited to 'modules/graceful/manager_windows.go')
-rw-r--r-- | modules/graceful/manager_windows.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/graceful/manager_windows.go b/modules/graceful/manager_windows.go index d412e94f9a..1ebdaa1970 100644 --- a/modules/graceful/manager_windows.go +++ b/modules/graceful/manager_windows.go @@ -73,7 +73,7 @@ func (g *Manager) start() { // Make SVC process run := svc.Run - isInteractive, err := svc.IsAnInteractiveSession() + isInteractive, err := svc.IsWindowsService() if err != nil { log.Error("Unable to ascertain if running as an Interactive Session: %v", err) return @@ -81,7 +81,9 @@ func (g *Manager) start() { if isInteractive { run = debug.Run } - go run(WindowsServiceName, g) + go func() { + _ = run(WindowsServiceName, g) + }() } // Execute makes Manager implement svc.Handler |