Merge pull request #53 from dcbw/addr-trim-whitespace

Trim whitespace from Addr.String()
This commit is contained in:
Vish Ishaya 2015-10-27 17:51:36 -07:00
commit 9168c87284

View File

@ -15,7 +15,7 @@ type Addr struct {
// String returns $ip/$netmask $label
func (a Addr) String() string {
return fmt.Sprintf("%s %s", a.IPNet, a.Label)
return strings.TrimSpace(fmt.Sprintf("%s %s", a.IPNet, a.Label))
}
// ParseAddr parses the string representation of an address in the