src/gedlib/charmaps.c
/*==========================================
 * step_xnode -- Step to node from character
 *========================================*/
- Step to node from character
- Step to node from character
static XNODE
step_xnode (XNODE node, INT achar)
{
	XNODE prev, node0 = node;
	if (node->child == NULL)
		return node->child = create_xnode(node0, achar, NULL);
	prev = NULL;
	node = node->child;
	while (node) {
		if (node->achar == achar) return node;
		prev = node;
		node = node->sibling;
	}
	return prev->sibling = create_xnode(node0, achar, NULL);
}
static XNODE step_xnode ( XNODE node , INT achar ) { XNODE prev , node0 = node ; if ( node -> child == NULL ) return node -> child = create_xnode ( node0 , achar , NULL ) ; prev = NULL ; node = node -> child ; while ( node ) { if ( node -> achar == achar ) return node ; prev = node ; node = node -> sibling ; } return prev -> sibling = create_xnode ( node0 , achar , NULL ) ; }
step_xnode -- Step to node from character
step_xnode -- Step to node from character