Fix host-device gofmt

Signed-off-by: Casey Callendrello <cdc@redhat.com>
This commit is contained in:
Casey Callendrello 2022-01-26 17:57:13 +01:00
parent 3b2afc93dc
commit 90e8e1faf9

View File

@ -270,7 +270,7 @@ func moveLinkOut(containerNs ns.NetNS, ifName string) error {
// function can be retried. Also bring the device back up, unless it was already down before.
if err != nil {
_ = netlink.LinkSetName(dev, ifName)
if dev.Attrs().Flags & net.FlagUp == net.FlagUp {
if dev.Attrs().Flags&net.FlagUp == net.FlagUp {
_ = netlink.LinkSetUp(dev)
}
}