mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-12-22 17:51:53 +00:00
tmp: enhancements in trie api changes
This commit is contained in:
parent
01e16f0e09
commit
7e68ba64a9
@ -854,9 +854,8 @@ trie_walk_init(struct f_trie_walk_state *s, const struct f_trie *t, const net_ad
|
||||
/* Save the last node on the stack otherwise */
|
||||
else
|
||||
{
|
||||
/* Found prefect match, no advancing */
|
||||
/* Found perfect match, no advancing of stack position */
|
||||
s->stack[s->stack_pos] = n;
|
||||
/* Search whole trie except skipped parts */
|
||||
s->start_pos = 1;
|
||||
}
|
||||
|
||||
|
@ -911,13 +911,13 @@ t_trie_walk_inclusive(void)
|
||||
bt_format_net(buf, 64, &px->net);
|
||||
bt_debug("%s{%d,%d}\n", buf, px->lo, px->hi);
|
||||
}
|
||||
*/
|
||||
|
||||
/* Full walk */
|
||||
bt_debug("Full walk inclusive (round %d, %d nets)\n", round, num);
|
||||
|
||||
pos = 0;
|
||||
uint pxc = 0;
|
||||
/* Last argument should have no effect on the walk */
|
||||
TRIE_WALK2(trie, net, NULL, 1)
|
||||
{
|
||||
log_networks(&net, &pxset[pos].net);
|
||||
@ -978,9 +978,9 @@ t_trie_walk_inclusive(void)
|
||||
break;
|
||||
|
||||
/* Account for subnets before searched net from */
|
||||
for (; pos < num; pos++)
|
||||
if (net_compare(&pxset[pos].net, &from.net) >= 0)
|
||||
break;
|
||||
//for (; pos < num; pos++)
|
||||
//if (net_compare(&pxset[pos].net, &from.net) >= 0)
|
||||
//break;
|
||||
|
||||
int p0 = pos;
|
||||
char buf0[64];
|
||||
|
Loading…
Reference in New Issue
Block a user