mirror of
https://github.com/opencontainers/runc.git
synced 2026-07-11 06:03:57 +08:00
@@ -335,7 +335,12 @@ func (l *LinuxFactory) StartInitialization() (err error) {
|
||||
|
||||
defer func() {
|
||||
if e := recover(); e != nil {
|
||||
err = fmt.Errorf("panic from initialization: %w, %v", e, string(debug.Stack()))
|
||||
if e, ok := e.(error); ok {
|
||||
err = fmt.Errorf("panic from initialization: %w, %s", e, debug.Stack())
|
||||
} else {
|
||||
//nolint:errorlint // here e is not of error type
|
||||
err = fmt.Errorf("panic from initialization: %v, %s", e, debug.Stack())
|
||||
}
|
||||
}
|
||||
}()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user