mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-11-08 12:18:42 +00:00
Minor fixes
This commit is contained in:
parent
d924d5a562
commit
304ac2e861
@ -916,9 +916,11 @@ static inline void ospf_send_to_des(struct ospf_iface *ifa)
|
|||||||
ospf_send_to_bdr(ifa);
|
ospf_send_to_bdr(ifa);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifndef PARSER
|
||||||
#define DROP(DSC,VAL) do { err_dsc = DSC; err_val = VAL; goto drop; } while(0)
|
#define DROP(DSC,VAL) do { err_dsc = DSC; err_val = VAL; goto drop; } while(0)
|
||||||
#define DROP1(DSC) do { err_dsc = DSC; goto drop; } while(0)
|
#define DROP1(DSC) do { err_dsc = DSC; goto drop; } while(0)
|
||||||
#define SKIP(DSC) do { err_dsc = DSC; goto skip; } while(0)
|
#define SKIP(DSC) do { err_dsc = DSC; goto skip; } while(0)
|
||||||
|
#endif
|
||||||
|
|
||||||
static inline uint ospf_pkt_hdrlen(struct ospf_proto *p)
|
static inline uint ospf_pkt_hdrlen(struct ospf_proto *p)
|
||||||
{ return ospf_is_v2(p) ? (sizeof(struct ospf_packet) + sizeof(union ospf_auth)) : sizeof(struct ospf_packet); }
|
{ return ospf_is_v2(p) ? (sizeof(struct ospf_packet) + sizeof(union ospf_auth)) : sizeof(struct ospf_packet); }
|
||||||
|
@ -247,7 +247,7 @@ krt_send_route(struct krt_proto *p, int cmd, rte *e)
|
|||||||
|
|
||||||
#ifdef IPV6
|
#ifdef IPV6
|
||||||
/* Embed interface ID to link-local address */
|
/* Embed interface ID to link-local address */
|
||||||
if (ipa_has_link_scope(gw))
|
if (ipa_is_link_local(gw))
|
||||||
_I0(gw) = 0xfe800000 | (i->index & 0x0000ffff);
|
_I0(gw) = 0xfe800000 | (i->index & 0x0000ffff);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -468,7 +468,7 @@ krt_read_route(struct ks_msg *msg, struct krt_proto *p, int scan)
|
|||||||
|
|
||||||
#ifdef IPV6
|
#ifdef IPV6
|
||||||
/* Clean up embedded interface ID returned in link-local address */
|
/* Clean up embedded interface ID returned in link-local address */
|
||||||
if (ipa_has_link_scope(a.gw))
|
if (ipa_is_link_local(a.gw))
|
||||||
_I0(a.gw) = 0xfe800000;
|
_I0(a.gw) = 0xfe800000;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -662,10 +662,10 @@ krt_read_addr(struct ks_msg *msg, int scan)
|
|||||||
#ifdef IPV6
|
#ifdef IPV6
|
||||||
/* Clean up embedded interface ID returned in link-local address */
|
/* Clean up embedded interface ID returned in link-local address */
|
||||||
|
|
||||||
if (ipa_has_link_scope(iaddr))
|
if (ipa_is_link_local(iaddr))
|
||||||
_I0(iaddr) = 0xfe800000;
|
_I0(iaddr) = 0xfe800000;
|
||||||
|
|
||||||
if (ipa_has_link_scope(ibrd))
|
if (ipa_is_link_local(ibrd))
|
||||||
_I0(ibrd) = 0xfe800000;
|
_I0(ibrd) = 0xfe800000;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user