summaryrefslogtreecommitdiffhomepage
path: root/pkg/server/server.go
diff options
context:
space:
mode:
authorHitoshi Irino <irino@sfc.wide.ad.jp>2018-08-17 19:41:32 +0900
committerFUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>2018-08-18 10:41:20 +0900
commitedbedebf7b048034eeed4bc7f442432d15d549d8 (patch)
tree9ace882d6b57e1b458fe208cd7e7ef200853adce /pkg/server/server.go
parent75254037d47ca8a6cf86604d8371d5db5db8464d (diff)
ZAPI5 (FRRouting version 5) support
Diffstat (limited to 'pkg/server/server.go')
-rw-r--r--pkg/server/server.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/pkg/server/server.go b/pkg/server/server.go
index 472da9ad..1ac5845b 100644
--- a/pkg/server/server.go
+++ b/pkg/server/server.go
@@ -621,13 +621,13 @@ func (server *BgpServer) notifyBestWatcher(best []*table.Path, multipath [][]*ta
clonedM[i] = clonePathList(pathList)
}
clonedB := clonePathList(best)
- m := make(map[string]uint16)
+ m := make(map[string]uint32)
for _, p := range clonedB {
switch p.GetRouteFamily() {
case bgp.RF_IPv4_VPN, bgp.RF_IPv6_VPN:
for _, vrf := range server.globalRib.Vrfs {
if vrf.Id != 0 && table.CanImportToVrf(vrf, p) {
- m[p.GetNlri().String()] = uint16(vrf.Id)
+ m[p.GetNlri().String()] = uint32(vrf.Id)
}
}
}
@@ -1547,7 +1547,7 @@ func (s *BgpServer) EnableZebra(ctx context.Context, r *api.EnableZebraRequest)
}
for _, p := range r.RouteTypes {
- if _, err := zebra.RouteTypeFromString(p); err != nil {
+ if _, err := zebra.RouteTypeFromString(p, uint8(r.Version)); err != nil {
return err
}
}
@@ -3387,7 +3387,7 @@ type WatchEventTable struct {
type WatchEventBestPath struct {
PathList []*table.Path
MultiPathList [][]*table.Path
- Vrf map[string]uint16
+ Vrf map[string]uint32
}
type WatchEventMessage struct {