mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-05 11:12:03 +00:00
Check killCmd is nil in Kill function
This commit is contained in:
@@ -314,9 +314,15 @@ type killCmd struct {
|
||||
}
|
||||
|
||||
func (k *killCmd) Kill() error {
|
||||
if k == nil {
|
||||
glog.V(2).Infof("The killCmd is nil, nothing will be killed")
|
||||
return nil
|
||||
}
|
||||
|
||||
if k.override != nil {
|
||||
return k.override.Run()
|
||||
}
|
||||
|
||||
name := k.name
|
||||
cmd := k.cmd
|
||||
|
||||
|
Reference in New Issue
Block a user