Skip to content

Commit

Permalink
Apply the proper node-index to the loopback-ip pool when announcing t…
Browse files Browse the repository at this point in the history
…he extended prefix for ospf2
  • Loading branch information
Hannes Gredler committed Sep 21, 2023
1 parent 48eac1d commit 04273b8
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions code/lspgen/src/lspgen.c
Original file line number Diff line number Diff line change
Expand Up @@ -590,6 +590,7 @@ lspgen_gen_ospf2_attr(struct lsdb_ctx_ *ctx)
/* IPv4 loopback prefix */
lsdb_reset_attr_template(&attr_template);
addr = lspgen_load_addr((uint8_t*)&ctx->ipv4_node_prefix.address, sizeof(ipv4addr_t));
addr += node->node_index;
lspgen_store_addr(addr, (uint8_t*)&attr_template.key.prefix.ipv4_prefix.address, sizeof(ipv4addr_t));
attr_template.key.prefix.ipv4_prefix.len = ctx->ipv4_node_prefix.len;
attr_template.key.attr_cp[0] = OSPF_MSG_LSUPDATE;
Expand Down

0 comments on commit 04273b8

Please sign in to comment.