From c0f5b38647c507f80bbaff5c26a2b43a19ed8e9a Mon Sep 17 00:00:00 2001 From: FengyunPan Date: Fri, 31 Mar 2017 18:56:38 +0800 Subject: [PATCH] Fix Judgment statement The 'i' can not be equal to updateNodeStatusMaxRetries in updateNetworkingCondition(), and can not get error. Let's update it. --- pkg/controller/route/routecontroller.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/controller/route/routecontroller.go b/pkg/controller/route/routecontroller.go index d2dc0410107..206eb291327 100644 --- a/pkg/controller/route/routecontroller.go +++ b/pkg/controller/route/routecontroller.go @@ -214,12 +214,13 @@ func (rc *RouteController) updateNetworkingCondition(nodeName types.NodeName, ro if err == nil { return nil } - if i == updateNodeStatusMaxRetries || !errors.IsConflict(err) { + if !errors.IsConflict(err) { glog.Errorf("Error updating node %s: %v", nodeName, err) return err } glog.Errorf("Error updating node %s, retrying: %v", nodeName, err) } + glog.Errorf("Error updating node %s: %v", nodeName, err) return err }