1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #13767 from duglin/TweakInNetOpts

Remove duplicate call to net.ParseIP
This commit is contained in:
Jessie Frazelle 2015-06-05 10:46:31 -07:00
commit 5c051e2e26

View file

@ -22,10 +22,10 @@ func (o *IpOpt) Set(val string) error {
if ip == nil { if ip == nil {
return fmt.Errorf("%s is not an ip address", val) return fmt.Errorf("%s is not an ip address", val)
} }
(*o.IP) = net.ParseIP(val) *o.IP = ip
return nil return nil
} }
func (o *IpOpt) String() string { func (o *IpOpt) String() string {
return (*o.IP).String() return o.IP.String()
} }