summaryrefslogtreecommitdiff
path: root/proto/bgp
diff options
context:
space:
mode:
authorOndrej Zajicek (work) <santiago@crfreenet.org>2017-12-08 14:00:36 +0100
committerOndrej Zajicek (work) <santiago@crfreenet.org>2017-12-08 14:00:36 +0100
commit49c7ef3b21e51ae7d1969baa52b4d8fd29b22eeb (patch)
treeb8f313e59fdd97c10119616bc97f044cd273fb43 /proto/bgp
parentccee67ca3b607130bf441b6060b88525b5e50ad9 (diff)
BGP: Fix IPv6 MPLS/VPN multicast SAFI
Diffstat (limited to 'proto/bgp')
-rw-r--r--proto/bgp/packets.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/proto/bgp/packets.c b/proto/bgp/packets.c
index 038e89f9..aa69bdd6 100644
--- a/proto/bgp/packets.c
+++ b/proto/bgp/packets.c
@@ -1483,7 +1483,8 @@ bgp_encode_nlri_vpn6(struct bgp_write_state *s, struct bgp_bucket *buck, byte *b
ADVANCE(pos, size, 1);
/* Encode MPLS labels */
- bgp_encode_mpls_labels(s, s->mpls_labels, &pos, &size, pos - 1);
+ if (s->mpls)
+ bgp_encode_mpls_labels(s, s->mpls_labels, &pos, &size, pos - 1);
/* Encode route distinguisher */
put_u64(pos, net->rd);