[main/vlan] Fix error handling for delegate IPAM plugin
Signed-off-by: Piotr Skamruk <piotr.skamruk@gmail.com>
This commit is contained in:
parent
48a97a7ad1
commit
075c5a0d67
@ -152,7 +152,7 @@ func cmdAdd(args *skel.CmdArgs) error {
|
|||||||
// run the IPAM plugin and get back the config to apply
|
// run the IPAM plugin and get back the config to apply
|
||||||
r, err := ipam.ExecAdd(n.IPAM.Type, args.StdinData)
|
r, err := ipam.ExecAdd(n.IPAM.Type, args.StdinData)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return fmt.Errorf("failed to execute IPAM delegate: %v", err)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Invoke ipam del if err to avoid ip leak
|
// Invoke ipam del if err to avoid ip leak
|
||||||
|
Loading…
x
Reference in New Issue
Block a user