|
|
|
|
@ -418,7 +418,7 @@ int route_bgp_add_path(struct NODEINFO_Q* nq, struct ETCP_CONN* conn, uint64_t*
|
|
|
|
|
return -1; |
|
|
|
|
} |
|
|
|
|
if (!nq->paths) { |
|
|
|
|
nq->paths = queue_new(conn->instance->ua, 32, "node_paths"); |
|
|
|
|
nq->paths = queue_new(conn->instance->ua, 0, "node_paths"); |
|
|
|
|
if (!nq->paths) return -1; |
|
|
|
|
} |
|
|
|
|
size_t hop_size = hop_count * 8; |
|
|
|
|
@ -534,8 +534,9 @@ int route_bgp_process_nodeinfo(struct ROUTE_BGP* bgp, struct ETCP_CONN* from,
|
|
|
|
|
return -1; |
|
|
|
|
} |
|
|
|
|
existing = (struct NODEINFO_Q*)entry; |
|
|
|
|
existing->paths = queue_new(bgp->instance->ua, 32, "node_paths"); |
|
|
|
|
queue_data_put_with_index(bgp->nodes, entry, offsetof(struct NODEINFO_Q, node.node_id), 8); |
|
|
|
|
existing->paths = queue_new(bgp->instance->ua, 0, "node_paths"); |
|
|
|
|
queue_data_put(bgp->nodes, entry); |
|
|
|
|
// queue_data_put_with_index(bgp->nodes, entry, offsetof(struct NODEINFO_Q, node.node_id)-sizeof(struct ll_entry), 8);
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
memcpy(&existing->node, ni, sizeof(struct NODEINFO)); |
|
|
|
|
|