예제 #1
0
파일: bttree.c 프로젝트: wtaysom/tau
static void pr_node (BtNode_s *node, int indent)
{
	if (!node) return;
	pr_indent(indent);
	printf("%p %s %d\n", node, pr_is_leaf(node), node->num);
	if (node->is_leaf) {
		pr_leaf(node, indent + 1);
	} else {
		pr_branch(node, indent + 1);
	}
}
예제 #2
0
파일: mtree.c 프로젝트: taysom/tau
static void pr_block(struct mtree *mt, u64 blknum, int indent)
{
	struct block *b;

	eaver(blknum);
	b = get_blk(mt->dev, blknum);
	if (isLeaf(b))
		pr_leaf(b->buf, indent+1);
	else
		pr_branch(mt, b->buf, indent+1);
	put_blk(b);
}