Browse Source

fix nil

pull/5150/merge
chrislu 3 weeks ago
parent
commit
decfb07eea
  1. 5
      weed/cluster/master_client.go

5
weed/cluster/master_client.go

@ -16,6 +16,9 @@ func ListExistingPeerUpdates(master pb.ServerAddress, grpcDialOption grpc.DialOp
ClientType: clientType, ClientType: clientType,
FilerGroup: filerGroup, FilerGroup: filerGroup,
}) })
if err != nil {
return err
}
glog.V(0).Infof("the cluster has %d %s\n", len(resp.ClusterNodes), clientType) glog.V(0).Infof("the cluster has %d %s\n", len(resp.ClusterNodes), clientType)
for _, node := range resp.ClusterNodes { for _, node := range resp.ClusterNodes {
@ -26,7 +29,7 @@ func ListExistingPeerUpdates(master pb.ServerAddress, grpcDialOption grpc.DialOp
CreatedAtNs: node.CreatedAtNs, CreatedAtNs: node.CreatedAtNs,
}) })
} }
return err
return nil
}); grpcErr != nil { }); grpcErr != nil {
glog.V(0).Infof("connect to %s: %v", master, grpcErr) glog.V(0).Infof("connect to %s: %v", master, grpcErr)
} }

Loading…
Cancel
Save