for(idx = pos; idx < last ; idx++) { if (p->child[idx]) { 
for (idx = pos; idx < last ; idx++) { if (!p->child[idx]) continue; 
static struct leaf *nextleaf(struct trie *t, struct leaf *thisleaf){	struct node *c = (struct node *) thisleaf;	struct tnode *p;	int idx;	if (c == NULL) {		if (t->trie == NULL)			return NULL;		if (IS_LEAF(t->trie))          /* trie w. just a leaf */			return (struct leaf *) t->trie;		p = (struct tnode*) t->trie;  /* Start */	}	else		p = (struct tnode *) NODE_PARENT(c);	while (p) {		int pos, last;		/*  Find the next child of the parent */		if (c)			pos = 1 + tkey_extract_bits(c->key, p->pos, p->bits);		else			pos = 0;		last = 1 << p->bits;		for(idx = pos; idx < last ; idx++) {			if (p->child[idx]) {				/* Decend if tnode */				while (IS_TNODE(p->child[idx])) {					p = (struct tnode*) p->child[idx];					idx = 0;									/* Rightmost non-NULL branch */					if (p && IS_TNODE(p))						while (p->child[idx] == NULL && idx < (1 << p->bits)) idx++;					/* Done with this tnode? */					if (idx >= (1 << p->bits) || p->child[idx] == NULL )						goto up;				}				return (struct leaf*) p->child[idx];			}		}up:		/* No more children go up one step  */		c = (struct node*) p;		p = (struct tnode *) NODE_PARENT(p);	}	return NULL; /* Ready. Root of trie */}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/91b9a277fc4d207249e459a455abf804ebb5499d/fib_trie.c/buggy/net/ipv4/fib_trie.c