Merge pull request #17192 from SuhasAnand/SuhasAnand-rbd-attachdisk-fix_unnecessary_call

Auto commit by PR queue bot
This commit is contained in:
k8s-merge-robot 2016-01-11 22:07:00 -08:00
commit 6f50699b93

View File

@ -237,13 +237,13 @@ func (util *RBDUtil) AttachDisk(b rbdBuilder) error {
break
}
}
}
if err != nil {
return err
}
devicePath, found = waitForPath(b.Pool, b.Image, 10)
if !found {
return errors.New("Could not map image: Timeout after 10s")
if err != nil {
return err
}
devicePath, found = waitForPath(b.Pool, b.Image, 10)
if !found {
return errors.New("Could not map image: Timeout after 10s")
}
}
// mount it
globalPDPath := b.manager.MakeGlobalPDName(*b.rbd)