From 3ff8a86f20f9a63be2d1ab7c1f0e42747ef6d2bb Mon Sep 17 00:00:00 2001 From: cyclinder Date: Tue, 28 Dec 2021 09:48:35 +0800 Subject: [PATCH] GCEPD: fix incorrect return value in WaitForAttach Signed-off-by: cyclinder --- pkg/volume/gcepd/attacher.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pkg/volume/gcepd/attacher.go b/pkg/volume/gcepd/attacher.go index 2a6349a511263..c97be9edcde0e 100644 --- a/pkg/volume/gcepd/attacher.go +++ b/pkg/volume/gcepd/attacher.go @@ -242,8 +242,9 @@ func (attacher *gcePersistentDiskAttacher) WaitForAttach(spec *volume.Spec, devi id, err := getDiskID(pdName, exec) if err != nil { klog.Errorf("WaitForAttach (windows) failed with error %s", err) + return "", err } - return id, err + return id, nil } partition := ""