mirror of
https://github.com/docker/cli.git
synced 2026-01-15 07:40:57 +03:00
Remove duplicate call to net.ParseIP
and a little cleanup Signed-off-by: Doug Davis <dug@us.ibm.com> Upstream-commit: b180de55caa382fd6ced4488d68392edd1d34da0 Component: engine
This commit is contained in:
@@ -22,10 +22,10 @@ func (o *IpOpt) Set(val string) error {
|
||||
if ip == nil {
|
||||
return fmt.Errorf("%s is not an ip address", val)
|
||||
}
|
||||
(*o.IP) = net.ParseIP(val)
|
||||
*o.IP = ip
|
||||
return nil
|
||||
}
|
||||
|
||||
func (o *IpOpt) String() string {
|
||||
return (*o.IP).String()
|
||||
return o.IP.String()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user