mirror of https://github.com/jetkvm/kvm.git
fix: ignore errors when crash log doesn't exist
This commit is contained in:
parent
99a60120e5
commit
72f29df835
|
|
@ -54,7 +54,9 @@ func checkFailsafeReason() {
|
|||
l := failsafeLogger.With().Str("path", lastCrashPath).Logger()
|
||||
fi, err := os.Lstat(lastCrashPath)
|
||||
if err != nil {
|
||||
l.Warn().Err(err).Msg("failed to stat last crash log")
|
||||
if !os.IsNotExist(err) {
|
||||
l.Warn().Err(err).Msg("failed to stat last crash log")
|
||||
}
|
||||
return
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue