From 07eab509aafddd72a34fa60269b0d1ccb1ded51f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B1=88=E8=BD=A9?= Date: Tue, 4 Dec 2018 19:49:49 +0800 Subject: [PATCH] =?UTF-8?q?=E9=81=BF=E5=85=8Deip=E4=B8=BA=E7=A9=BA?= =?UTF-8?q?=E8=BF=94=E5=9B=9E=E5=85=B6=E4=BB=96=E7=9A=84eip?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pkg/util/qcloud/region.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pkg/util/qcloud/region.go b/pkg/util/qcloud/region.go index c7b36954ed..c368f79895 100644 --- a/pkg/util/qcloud/region.go +++ b/pkg/util/qcloud/region.go @@ -91,6 +91,9 @@ func (self *SRegion) GetClient() *SQcloudClient { } func (self *SRegion) GetIEipById(eipId string) (cloudprovider.ICloudEIP, error) { + if len(eipId) == 0 { + return nil, cloudprovider.ErrNotFound + } eips, total, err := self.GetEips(eipId, "", 0, 1) if err != nil { return nil, err