From b771ba8956c0592740a06278ec2eb554dbf73948 Mon Sep 17 00:00:00 2001 From: Sage Weil Date: Tue, 26 Oct 2010 19:20:38 -0700 Subject: [PATCH] mds: simplify fragtree_t printer val/bits^split Signed-off-by: Sage Weil --- src/include/frag.h | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/include/frag.h b/src/include/frag.h index 045464f2bb37d..aeb824fa65726 100644 --- a/src/include/frag.h +++ b/src/include/frag.h @@ -513,11 +513,20 @@ inline std::ostream& operator<<(std::ostream& out, fragtree_t& ft) } } } - if (1) { + if (0) { std::list leaves; ft.get_leaves(leaves); out << leaves; } + if (1) { + for (std::map::const_iterator p = ft._splits.begin(); + p != ft._splits.end(); + p++) { + if (p != ft._splits.begin()) + out << " "; + out << p->first << "^" << p->second; + } + } return out << ")"; } -- 2.39.5