diff options
author | Yan, Zheng <zheng.z.yan@intel.com> | 2013-09-23 15:28:52 +0800 |
---|---|---|
committer | Yan, Zheng <zheng.z.yan@intel.com> | 2013-09-24 08:45:56 +0800 |
commit | 9e6b0404a867c074607a03ce4e7d46c46b903b7a (patch) | |
tree | ba45783da60427363848087aef4ddf136208c1d1 | |
parent | 116bf1615c5c894f40cb3a7a299e2c9f427449f2 (diff) | |
download | ceph-9e6b0404a867c074607a03ce4e7d46c46b903b7a.tar.gz |
fragtree_t: fix get_leaves_under()
If fragtree is (*^1, 1*^1) and we want leaves under frag 000*.
get_leaves_under() return frag 0*, frag 10* and frag 11*. This is
obviously wrong.
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
-rw-r--r-- | src/include/frag.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/include/frag.h b/src/include/frag.h index 715eb098283..fbe5b43f8cb 100644 --- a/src/include/frag.h +++ b/src/include/frag.h @@ -285,7 +285,7 @@ public: */ void get_leaves_under(frag_t x, std::list<frag_t>& ls) const { std::list<frag_t> q; - q.push_back(get_branch(x)); + q.push_back(get_branch_or_leaf(x)); while (!q.empty()) { frag_t t = q.front(); q.pop_front(); |