diff options
author | Yan, Zheng <zheng.z.yan@intel.com> | 2013-09-19 13:44:55 +0800 |
---|---|---|
committer | Yan, Zheng <zheng.z.yan@intel.com> | 2013-10-05 11:31:11 +0800 |
commit | fe99882583d7373a71a3a1c22bddc8452d140a0a (patch) | |
tree | ab977c23798eb591a8e2837694f9561c36a51aa1 | |
parent | 473635ab03bdeb9e591a15ff9eb9fcae08ec272f (diff) | |
download | ceph-fe99882583d7373a71a3a1c22bddc8452d140a0a.tar.gz |
mds: fix CInode::get_dirfrags_under()
make sure it return true when all dirfrags under the given frag_t
are found.
Signed-off-by: Yan, Zheng <zheng.z.yan@intel.com>
-rw-r--r-- | src/mds/CInode.cc | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/src/mds/CInode.cc b/src/mds/CInode.cc index 7accc5a4dba..a95a892684f 100644 --- a/src/mds/CInode.cc +++ b/src/mds/CInode.cc @@ -458,13 +458,6 @@ frag_t CInode::pick_dirfrag(const string& dn) bool CInode::get_dirfrags_under(frag_t fg, list<CDir*>& ls) { bool all = true; - for (map<frag_t,CDir*>::iterator p = dirfrags.begin(); p != dirfrags.end(); ++p) { - if (fg.contains(p->first)) - ls.push_back(p->second); - else - all = false; - } - /* list<frag_t> fglist; dirfragtree.get_leaves_under(fg, fglist); for (list<frag_t>::iterator p = fglist.begin(); @@ -474,7 +467,6 @@ bool CInode::get_dirfrags_under(frag_t fg, list<CDir*>& ls) ls.push_back(dirfrags[*p]); else all = false; - */ return all; } |