summaryrefslogtreecommitdiffhomepage
path: root/packet
diff options
context:
space:
mode:
Diffstat (limited to 'packet')
-rw-r--r--packet/bgp/bgp.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/packet/bgp/bgp.go b/packet/bgp/bgp.go
index c01859fe..17d11f4e 100644
--- a/packet/bgp/bgp.go
+++ b/packet/bgp/bgp.go
@@ -7081,9 +7081,12 @@ func (e *MessageError) Error() string {
}
func (l *LabeledVPNIPAddrPrefix) Flat() map[string]string {
+ prefixLen := l.IPAddrPrefixDefault.Length - uint8(8*(l.Labels.Len()+l.RD.Len()))
return map[string]string{
"Prefix": l.IPAddrPrefixDefault.Prefix.String(),
- "PrefixLen": string(l.IPAddrPrefixDefault.Length - uint8(8*(l.Labels.Len()+l.RD.Len())))}
+ "PrefixLen": fmt.Sprintf("%d", prefixLen),
+ "NLRI": l.String(),
+ }
}
func (p *IPAddrPrefixDefault) Flat() map[string]string {