fix: 前台运行会退出后台程序的问题

This commit is contained in:
Mmx
2021-11-26 08:41:34 +08:00
parent 629efcfe8a
commit f0bd58cbf5

View File

@@ -11,10 +11,12 @@ import (
func Guardian(output bool) {
util.Log.OutPut = output
go Daemon.DaemonChan()
if global.Config.Settings.Daemon.Enable {
go Daemon.DaemonChan()
if e := Daemon.MarkDaemon(); e != nil {
util.Log.Fatalln(e)
if e := Daemon.MarkDaemon(); e != nil {
util.Log.Fatalln(e)
}
}
var c = make(chan bool)