[client] Log windows panics (#2829)

This commit is contained in:
Viktor Liu
2024-11-01 15:08:22 +01:00
committed by GitHub
parent 0eb99c266a
commit 5f06b202c3
3 changed files with 94 additions and 0 deletions

View File

@ -97,6 +97,10 @@ func (s *Server) Start() error {
defer s.mutex.Unlock()
state := internal.CtxGetState(s.rootCtx)
if err := handlePanicLog(); err != nil {
log.Warnf("failed to redirect stderr: %v", err)
}
if err := restoreResidualState(s.rootCtx); err != nil {
log.Warnf(errRestoreResidualState, err)
}