mirror of
https://github.com/ceph/ceph
synced 2025-02-19 08:57:27 +00:00
mds: use list instead of vector for trim_unlinked_inodes
Signed-off-by: Sage Weil <sage@newdream.net>
This commit is contained in:
parent
4e180fef33
commit
96e583d375
@ -2728,7 +2728,7 @@ void MDCache::remove_inode_recursive(CInode *in)
|
||||
void MDCache::trim_unlinked_inodes()
|
||||
{
|
||||
dout(7) << "trim_unlinked_inodes" << dendl;
|
||||
vector<CInode*> q;
|
||||
list<CInode*> q;
|
||||
for (hash_map<vinodeno_t,CInode*>::iterator p = inode_map.begin();
|
||||
p != inode_map.end();
|
||||
p++) {
|
||||
@ -2738,7 +2738,7 @@ void MDCache::trim_unlinked_inodes()
|
||||
q.push_back(in);
|
||||
}
|
||||
}
|
||||
for (vector<CInode*>::iterator p = q.begin(); p != q.end(); p++)
|
||||
for (list<CInode*>::iterator p = q.begin(); p != q.end(); p++)
|
||||
remove_inode_recursive(*p);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user