🐛 修复 WebSSH 连接断开后遗留僵尸进程

This commit is contained in:
naiba
2021-09-30 12:01:01 +08:00
parent a25a1b128d
commit 7422de1269
4 changed files with 49 additions and 11 deletions

View File

@@ -64,7 +64,9 @@ func GetHost() *model.Host {
swapMemTotal = mv.SwapTotal
}
cachedBootTime = time.Unix(int64(hi.BootTime), 0)
if cachedBootTime.IsZero() {
cachedBootTime = time.Unix(int64(hi.BootTime), 0)
}
return &model.Host{
Platform: hi.OS,