diff options
author | Maria Matejka <mq@ucw.cz> | 2019-07-15 16:07:16 +0200 |
---|---|---|
committer | Maria Matejka <mq@ucw.cz> | 2019-07-15 16:07:16 +0200 |
commit | 8263690e754a83b8f3c58bd0080a1628d6cba556 (patch) | |
tree | 9c0503f0a166b72f018ae3c2e0de0e91d089a62a /proto/ospf/dbdes.c | |
parent | efd7c87b5bcd476ba74ffe9f369e2f6fe978cbb1 (diff) | |
parent | 1aec7112f7314c3e9a4d8b9440dd85a782295310 (diff) |
Merge remote-tracking branch 'origin/master' into mq-filter-stack
Diffstat (limited to 'proto/ospf/dbdes.c')
-rw-r--r-- | proto/ospf/dbdes.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/proto/ospf/dbdes.c b/proto/ospf/dbdes.c index b39595d9..5a5f76f8 100644 --- a/proto/ospf/dbdes.c +++ b/proto/ospf/dbdes.c @@ -127,7 +127,7 @@ ospf_prepare_dbdes(struct ospf_proto *p, struct ospf_neighbor *n) { struct ospf_dbdes2_packet *ps = (void *) pkt; ps->iface_mtu = htons(iface_mtu); - ps->options = ifa->oa->options | OPT_O; + ps->options = ifa->oa->options & DBDES2_OPT_MASK; ps->imms = 0; /* Will be set later */ ps->ddseq = htonl(n->dds); length = sizeof(struct ospf_dbdes2_packet); @@ -135,7 +135,8 @@ ospf_prepare_dbdes(struct ospf_proto *p, struct ospf_neighbor *n) else /* OSPFv3 */ { struct ospf_dbdes3_packet *ps = (void *) pkt; - ps->options = htonl(ifa->oa->options | (ifa->autype == OSPF_AUTH_CRYPT ? OPT_AT : 0)); + u32 options = ifa->oa->options | (ifa->autype == OSPF_AUTH_CRYPT ? OPT_AT : 0); + ps->options = htonl(options & DBDES3_OPT_MASK); ps->iface_mtu = htons(iface_mtu); ps->padding = 0; ps->imms = 0; /* Will be set later */ |