diff options
| author | Christian Franke <chris@opensourcerouting.org> | 2017-04-27 12:56:11 +0200 |
|---|---|---|
| committer | Christian Franke <chris@opensourcerouting.org> | 2017-04-28 12:03:23 +0200 |
| commit | 316a98ecd151dfba86a4a87e11c98cb2a0e94518 (patch) | |
| tree | dbbf666c211c4458f4313fbfd5043befff46be69 /isisd/isis_pfpacket.c | |
| parent | 1b49e4f0ba4073821701cb339bde94055d3b5786 (diff) | |
isisd: implement draft-ietf-isis-ext-eth and support p2p over LAN on BSD
Signed-off-by: Christian Franke <chris@opensourcerouting.org>
Diffstat (limited to 'isisd/isis_pfpacket.c')
| -rw-r--r-- | isisd/isis_pfpacket.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/isisd/isis_pfpacket.c b/isisd/isis_pfpacket.c index dd07a9c6f5..5c434b90d1 100644 --- a/isisd/isis_pfpacket.c +++ b/isisd/isis_pfpacket.c @@ -371,7 +371,9 @@ isis_send_pdu_bcast (struct isis_circuit *circuit, int level) stream_set_getp (circuit->snd_stream, 0); memset (&sa, 0, sizeof (struct sockaddr_ll)); sa.sll_family = AF_PACKET; - sa.sll_protocol = htons (stream_get_endp (circuit->snd_stream) + LLC_LEN); + + size_t frame_size = stream_get_endp(circuit->snd_stream) + LLC_LEN; + sa.sll_protocol = htons(isis_ethertype(frame_size)); sa.sll_ifindex = circuit->interface->ifindex; sa.sll_halen = ETH_ALEN; /* RFC5309 section 4.1 recommends ALL_ISS */ @@ -418,7 +420,6 @@ isis_send_pdu_p2p (struct isis_circuit *circuit, int level) stream_set_getp (circuit->snd_stream, 0); memset (&sa, 0, sizeof (struct sockaddr_ll)); sa.sll_family = AF_PACKET; - sa.sll_protocol = htons (stream_get_endp (circuit->snd_stream) + LLC_LEN); sa.sll_ifindex = circuit->interface->ifindex; sa.sll_halen = ETH_ALEN; if (level == 1) |
