Merge pull request #17894 from mqliang/deferMove
move defer statement for readability Upstream-commit: 6c82fba2b32781e6cef4fda71e7b35c3dcdcb9da Component: engine
This commit is contained in:
@@ -136,8 +136,8 @@ func (m *containerMonitor) Start() error {
|
||||
defer func() {
|
||||
if afterRun {
|
||||
m.container.Lock()
|
||||
m.container.setStopped(&exitStatus)
|
||||
defer m.container.Unlock()
|
||||
m.container.setStopped(&exitStatus)
|
||||
}
|
||||
m.Close()
|
||||
}()
|
||||
|
||||
Reference in New Issue
Block a user