From: John Spray Date: Tue, 6 May 2014 15:45:17 +0000 (+0100) Subject: fragtree: remove dead code X-Git-Tag: v0.81~43^2~6 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=8584b40686080b488f80eb8944768babde47da9b;p=ceph.git fragtree: remove dead code Signed-off-by: John Spray --- diff --git a/src/include/frag.h b/src/include/frag.h index f98765a30c7b..2cf6399ad8ef 100644 --- a/src/include/frag.h +++ b/src/include/frag.h @@ -514,33 +514,12 @@ inline std::ostream& operator<<(std::ostream& out, const fragtree_t& ft) { out << "fragtree_t("; - if (0) { - std::list q; - q.push_back(frag_t()); - while (!q.empty()) { - frag_t t = q.front(); - q.pop_front(); - int nb = ft.get_split(t); - if (nb) { - if (t.bits()) out << ' '; - out << t << '%' << nb; - t.split(nb, q); // queue up children - } - } - } - 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; - } + 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 << ")"; }