mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 19:31:44 +00:00
Merge pull request #4899 from lhuard1A/fix_panic_kube_apiserver
Fix nil pointer dereference in kube-apiserver when etcd is not there
This commit is contained in:
commit
900d58ec94
@ -214,6 +214,7 @@ func (p *PodCache) GarbageCollectPodStatus() {
|
||||
pods, err := p.pods.ListPods(api.NewContext(), labels.Everything())
|
||||
if err != nil {
|
||||
glog.Errorf("Error getting pod list: %v", err)
|
||||
return
|
||||
}
|
||||
keys := map[objKey]bool{}
|
||||
for _, pod := range pods.Items {
|
||||
|
Loading…
Reference in New Issue
Block a user