diff --git a/pkg/ip/ipmasq_iptables_linux.go b/pkg/ip/ipmasq_iptables_linux.go index dd88ec07e..0db3b5173 100644 --- a/pkg/ip/ipmasq_iptables_linux.go +++ b/pkg/ip/ipmasq_iptables_linux.go @@ -171,7 +171,7 @@ func gcIPMasqIPTables(_ string, _ []types.GCAttachment) error { return nil } -// isNotExist returnst true if the error is from iptables indicating +// isNotExist returns true if the error is from iptables indicating // that the target does not exist. func isNotExist(err error) bool { e, ok := err.(*iptables.Error) diff --git a/plugins/main/bridge/bridge.go b/plugins/main/bridge/bridge.go index a9dde012c..369780877 100644 --- a/plugins/main/bridge/bridge.go +++ b/plugins/main/bridge/bridge.go @@ -403,12 +403,12 @@ func ensureVlanInterface(br *netlink.Bridge, vlanID int, preserveDefaultVlan boo hostNS, err := ns.GetCurrentNS() if err != nil { - return nil, fmt.Errorf("faild to find host namespace: %v", err) + return nil, fmt.Errorf("failed to find host namespace: %v", err) } _, brGatewayIface, err := setupVeth(hostNS, br, name, br.MTU, false, vlanID, nil, preserveDefaultVlan, "", false) if err != nil { - return nil, fmt.Errorf("faild to create vlan gateway %q: %v", name, err) + return nil, fmt.Errorf("failed to create vlan gateway %q: %v", name, err) } brGatewayVeth, err = netlinksafe.LinkByName(brGatewayIface.Name) @@ -1044,7 +1044,7 @@ func cmdCheck(args *skel.CmdArgs) error { var contCNI, vethCNI cniBridgeIf var brMap, contMap current.Interface - // Find interfaces for names whe know, CNI Bridge and container + // Find interfaces for names we know, CNI Bridge and container for _, intf := range result.Interfaces { if n.BrName == intf.Name { brMap = *intf diff --git a/plugins/main/dummy/dummy.go b/plugins/main/dummy/dummy.go index 493143698..bea90d0ef 100644 --- a/plugins/main/dummy/dummy.go +++ b/plugins/main/dummy/dummy.go @@ -226,7 +226,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for name whe know, that of dummy device inside container + // Find interfaces for name we know, that of dummy device inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/main/host-device/host-device.go b/plugins/main/host-device/host-device.go index 5ad5c5c0b..e9c9cf3c1 100644 --- a/plugins/main/host-device/host-device.go +++ b/plugins/main/host-device/host-device.go @@ -311,7 +311,7 @@ func moveLinkIn(hostDev netlink.Link, containerNs ns.NetNS, containerIfName stri return fmt.Errorf("failed to find %q in tempNS: %v", hostDevName, err) } - // detroying a non empty tempNS would move physical devices back to the initial net namespace, + // destroying a non empty tempNS would move physical devices back to the initial net namespace, // not the namespace of the "parent" process, and virtual devices would be destroyed, // so we need to actively move the device back to hostNS on error defer func() { diff --git a/plugins/main/ipvlan/ipvlan.go b/plugins/main/ipvlan/ipvlan.go index 29d0de5ea..72a843045 100644 --- a/plugins/main/ipvlan/ipvlan.go +++ b/plugins/main/ipvlan/ipvlan.go @@ -394,7 +394,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for names whe know, ipvlan inside container + // Find interfaces for names we know, ipvlan inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/main/macvlan/macvlan.go b/plugins/main/macvlan/macvlan.go index b3177fe68..88ba86d3f 100644 --- a/plugins/main/macvlan/macvlan.go +++ b/plugins/main/macvlan/macvlan.go @@ -474,7 +474,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for names whe know, macvlan device name inside container + // Find interfaces for names we know, macvlan device name inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/main/ptp/ptp.go b/plugins/main/ptp/ptp.go index 9c88d9010..0981aaf69 100644 --- a/plugins/main/ptp/ptp.go +++ b/plugins/main/ptp/ptp.go @@ -342,7 +342,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for name whe know, that of host-device inside container + // Find interfaces for name we know, that of host-device inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/main/tap/tap.go b/plugins/main/tap/tap.go index b16bfdcdb..eea3c8d2a 100644 --- a/plugins/main/tap/tap.go +++ b/plugins/main/tap/tap.go @@ -431,7 +431,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for names whe know, tap device name inside container + // Find interfaces for names we know, tap device name inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/main/vlan/vlan.go b/plugins/main/vlan/vlan.go index c0bfe875e..da028869e 100644 --- a/plugins/main/vlan/vlan.go +++ b/plugins/main/vlan/vlan.go @@ -335,7 +335,7 @@ func cmdCheck(args *skel.CmdArgs) error { } var contMap current.Interface - // Find interfaces for name whe know, that of host-device inside container + // Find interfaces for name we know, that of host-device inside container for _, intf := range result.Interfaces { if args.IfName == intf.Name { if args.Netns == intf.Sandbox { diff --git a/plugins/meta/portmap/main.go b/plugins/meta/portmap/main.go index 913e371a9..8d7d4800a 100644 --- a/plugins/meta/portmap/main.go +++ b/plugins/meta/portmap/main.go @@ -22,7 +22,7 @@ // This has one notable limitation: it does not perform any kind of reservation // of the actual host port. If there is a service on the host, it will have all // its traffic captured by the container. If another container also claims a given -// port, it will caputure the traffic - it is last-write-wins. +// port, it will capture the traffic - it is last-write-wins. package main import (