From 51ec188af795c202f8f8ed30a9e0baa0149423a4 Mon Sep 17 00:00:00 2001 From: bin liu Date: Mon, 4 May 2015 09:54:19 +0000 Subject: [PATCH] fix some typos Signed-off-by: bin liu --- client/client.go | 2 +- client/client_test.go | 2 +- drivers/bridge/bridge.go | 2 +- drivers/bridge/error.go | 2 +- netutils/utils.go | 4 ++-- sandbox/namespace_linux.go | 2 +- 6 files changed, 7 insertions(+), 7 deletions(-) diff --git a/client/client.go b/client/client.go index 8ddca2b..5c3bda6 100644 --- a/client/client.go +++ b/client/client.go @@ -22,7 +22,7 @@ type NetworkCli struct { call CallFunc } -// NewNetworkCli is a conveninent function to create a NetworkCli object +// NewNetworkCli is a convenient function to create a NetworkCli object func NewNetworkCli(out, err io.Writer, call CallFunc) *NetworkCli { return &NetworkCli{ out: out, diff --git a/client/client_test.go b/client/client_test.go index 2e54be6..d0a2b61 100644 --- a/client/client_test.go +++ b/client/client_test.go @@ -160,7 +160,7 @@ func TestClientNetworkCreateHelp(t *testing.T) { } */ -// Docker flag processing in flag.go uses os.Exit(1) for incorrect paramater case. +// Docker flag processing in flag.go uses os.Exit(1) for incorrect parameter case. // TODO : Handle the missing argument case in the IT when CLI is available /* func TestClientNetworkCreateMissingArgument(t *testing.T) { diff --git a/drivers/bridge/bridge.go b/drivers/bridge/bridge.go index 353fd7f..81180fc 100644 --- a/drivers/bridge/bridge.go +++ b/drivers/bridge/bridge.go @@ -279,7 +279,7 @@ func (d *driver) CreateNetwork(id types.UUID, option map[string]interface{}) err // Even if a bridge exists try to setup IPv4. bridgeSetup.queueStep(setupBridgeIPv4) - // Conditionnally queue setup steps depending on configuration values. + // Conditionally queue setup steps depending on configuration values. for _, step := range []struct { Condition bool Fn setupStep diff --git a/drivers/bridge/error.go b/drivers/bridge/error.go index c581c32..9f53e9a 100644 --- a/drivers/bridge/error.go +++ b/drivers/bridge/error.go @@ -59,7 +59,7 @@ func (uat ErrUnsupportedAddressType) Error() string { return fmt.Sprintf("unsupported address type: %s", string(uat)) } -// ErrInvalidAddressBinding is returned when the host address specfied in the port binding is not valid. +// ErrInvalidAddressBinding is returned when the host address specified in the port binding is not valid. type ErrInvalidAddressBinding string func (iab ErrInvalidAddressBinding) Error() string { diff --git a/netutils/utils.go b/netutils/utils.go index 158b299..ddb7190 100644 --- a/netutils/utils.go +++ b/netutils/utils.go @@ -53,7 +53,7 @@ type PortBinding struct { HostPort uint16 } -// HostAddr returns the host side tranport address +// HostAddr returns the host side transport address func (p PortBinding) HostAddr() (net.Addr, error) { switch p.Proto { case UDP: @@ -65,7 +65,7 @@ func (p PortBinding) HostAddr() (net.Addr, error) { } } -// ContainerAddr returns the container side tranport address +// ContainerAddr returns the container side transport address func (p PortBinding) ContainerAddr() (net.Addr, error) { switch p.Proto { case UDP: diff --git a/sandbox/namespace_linux.go b/sandbox/namespace_linux.go index 17bae5f..4a74896 100644 --- a/sandbox/namespace_linux.go +++ b/sandbox/namespace_linux.go @@ -173,7 +173,7 @@ func (n *networkNamespace) AddInterface(i *Interface) error { } defer f.Close() - // Find the network inteerface identified by the SrcName attribute. + // Find the network interface identified by the SrcName attribute. iface, err := netlink.LinkByName(i.SrcName) if err != nil { return err