Skip to content

Commit

Permalink
Merge pull request #1264 from k8s-infra-cherrypick-robot/cherry-pick-…
Browse files Browse the repository at this point in the history
…1258-to-release-0.13

[release-0.13] nfd-master: check for nil references in nfdAPIUpdateAllNodes
  • Loading branch information
k8s-ci-robot committed Jul 18, 2023
2 parents d22e871 + f0026a9 commit 455255a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions pkg/nfd-master/nfd-master.go
Original file line number Diff line number Diff line change
Expand Up @@ -633,6 +633,10 @@ func (m *nfdMaster) nfdAPIUpdateAllNodes() error {
}

func (m *nfdMaster) nfdAPIUpdateOneNode(nodeName string) error {
if m.nfdController == nil || m.nfdController.featureLister == nil {
return nil
}

sel := k8sLabels.SelectorFromSet(k8sLabels.Set{nfdv1alpha1.NodeFeatureObjNodeNameLabel: nodeName})
objs, err := m.nfdController.featureLister.List(sel)
if err != nil {
Expand Down

0 comments on commit 455255a

Please sign in to comment.