From 11963d4fac77140905d85541dc4ffb638475e6a4 Mon Sep 17 00:00:00 2001 From: smail Date: Tue, 1 Sep 2026 11:23:05 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8DWindows=E6=9C=8D=E5=8A=A1?= =?UTF-8?q?=E5=85=A5=E5=8F=A3=E6=9E=84=E5=BB=BA=E5=85=BC=E5=AE=B9=E6=80=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server/cmd/smail/run_windows.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/server/cmd/smail/run_windows.go b/server/cmd/smail/run_windows.go index d0fc7663..fc7da418 100644 --- a/server/cmd/smail/run_windows.go +++ b/server/cmd/smail/run_windows.go @@ -11,7 +11,11 @@ import ( ) func runMain() error { - if !svc.IsWindowsService() { + windowsServiceMode, err := svc.IsWindowsService() + if err != nil { + return err + } + if !windowsServiceMode { return app.RecoverPanic(app.Run) } return svc.Run("Smail", &windowsService{})