| ... | ... |
@@ -9,7 +9,7 @@ import ( |
| 9 | 9 |
"github.com/docker/docker/api/types/strslice" |
| 10 | 10 |
) |
| 11 | 11 |
|
| 12 |
-// KeyValuePair represent an arbitrary named value (usefull in slice insted of map[string] string to preserve ordering) |
|
| 12 |
+// KeyValuePair represent an arbitrary named value (useful in slice insted of map[string] string to preserve ordering) |
|
| 13 | 13 |
type KeyValuePair struct {
|
| 14 | 14 |
Key string |
| 15 | 15 |
Value string |
| ... | ... |
@@ -105,7 +105,7 @@ func ParseCommand(node *parser.Node) (Command, error) {
|
| 105 | 105 |
return nil, errors.Errorf("%T is not a command type", s)
|
| 106 | 106 |
} |
| 107 | 107 |
|
| 108 |
-// UnknownInstruction represents an error occuring when a command is unresolvable |
|
| 108 |
+// UnknownInstruction represents an error occurring when a command is unresolvable |
|
| 109 | 109 |
type UnknownInstruction struct {
|
| 110 | 110 |
Line int |
| 111 | 111 |
Instruction string |
| ... | ... |
@@ -42,7 +42,7 @@ type AttachmentStore struct {
|
| 42 | 42 |
networkToNodeLBIP map[string]net.IP |
| 43 | 43 |
} |
| 44 | 44 |
|
| 45 |
-// ResetAttachments clears any exsiting load balancer IP to network mapping and |
|
| 45 |
+// ResetAttachments clears any existing load balancer IP to network mapping and |
|
| 46 | 46 |
// sets the mapping to the given attachments. |
| 47 | 47 |
func (store *AttachmentStore) ResetAttachments(attachments map[string]string) error {
|
| 48 | 48 |
store.ClearAttachments() |
| ... | ... |
@@ -333,7 +333,7 @@ func (s *DockerSwarmSuite) AddDaemon(c *check.C, joinSwarm, manager bool) *daemo |
| 333 | 333 |
args := []string{"--iptables=false", "--swarm-default-advertise-addr=lo"} // avoid networking conflicts
|
| 334 | 334 |
d.StartWithBusybox(c, args...) |
| 335 | 335 |
|
| 336 |
- if joinSwarm == true {
|
|
| 336 |
+ if joinSwarm {
|
|
| 337 | 337 |
if len(s.daemons) > 0 {
|
| 338 | 338 |
tokens := s.daemons[0].JoinTokens(c) |
| 339 | 339 |
token := tokens.Worker |
| ... | ... |
@@ -44,11 +44,7 @@ func testIpcCheckDevExists(mm string) (bool, error) {
|
| 44 | 44 |
} |
| 45 | 45 |
} |
| 46 | 46 |
|
| 47 |
- if err := s.Err(); err != nil {
|
|
| 48 |
- return false, err |
|
| 49 |
- } |
|
| 50 |
- |
|
| 51 |
- return false, nil |
|
| 47 |
+ return false, s.Err() |
|
| 52 | 48 |
} |
| 53 | 49 |
|
| 54 | 50 |
// testIpcNonePrivateShareable is a helper function to test "none", |
| ... | ... |
@@ -42,7 +42,7 @@ func linuxValidateAbsolute(p string) error {
|
| 42 | 42 |
} |
| 43 | 43 |
func (p *linuxParser) validateMountConfig(mnt *mount.Mount) error {
|
| 44 | 44 |
// there was something looking like a bug in existing codebase: |
| 45 |
- // - validateMountConfig on linux was called with options skipping bind source existance when calling ParseMountRaw |
|
| 45 |
+ // - validateMountConfig on linux was called with options skipping bind source existence when calling ParseMountRaw |
|
| 46 | 46 |
// - but not when calling ParseMountSpec directly... nor when the unit test called it directly |
| 47 | 47 |
return p.validateMountConfigImpl(mnt, true) |
| 48 | 48 |
} |