Dst may be nil, so don't force it to String()

Fixes #14
This commit is contained in:
Vishvananda Ishaya 2015-01-14 07:59:00 -08:00
parent 80a80badbd
commit 7663a3b4b6
1 changed files with 1 additions and 1 deletions

View File

@ -30,6 +30,6 @@ type Route struct {
}
func (r Route) String() string {
return fmt.Sprintf("{Ifindex: %d Dst: %s Src: %s Gw: %s}", r.LinkIndex, r.Dst.String(),
return fmt.Sprintf("{Ifindex: %d Dst: %s Src: %s Gw: %s}", r.LinkIndex, r.Dst,
r.Src, r.Gw)
}