diff --git a/plugin/ipam/driver.go b/plugin/ipam/driver.go index 766aa9a1..8cd6142f 100644 --- a/plugin/ipam/driver.go +++ b/plugin/ipam/driver.go @@ -33,6 +33,9 @@ func (i *ipam) RequestPool(addressSpace, pool, subPool string, options map[strin Log.Debugln("RequestPool", addressSpace, pool, subPool, options) cidr, err := i.weave.DefaultSubnet() Log.Debugln("RequestPool returning ", cidr, err) + if err != nil { + return "", nil, nil, err + } // Pass back a fake "gateway address"; we don't actually use it, // so just give the network address. data := map[string]string{netlabel.Gateway: cidr.String()}