]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds/mdcache: fix get poolid in open_remote_dentry
authorhuanwen ren <rhwlyw@163.com>
Sun, 12 Jun 2016 08:54:48 +0000 (16:54 +0800)
committerGitHub <noreply@github.com>
Sun, 12 Jun 2016 08:54:48 +0000 (16:54 +0800)
if dnl->get_remote_d_type() == DT_DIR not establish, then pool = -1
so the type of pool should be int64_t not uint64_t

Signed-off-by: huanwen ren <ren.huanwen@zte.com.cn>
src/mds/MDCache.cc

index 2a45b29b447a347a32aad2d961ff590acf9e3758..ffa17ec1444f1a2942d6a005a7e208aa66683dc8 100644 (file)
@@ -8077,7 +8077,7 @@ void MDCache::open_remote_dentry(CDentry *dn, bool projected, MDSInternalContext
   dout(10) << "open_remote_dentry " << *dn << dendl;
   CDentry::linkage_t *dnl = projected ? dn->get_projected_linkage() : dn->get_linkage();
   inodeno_t ino = dnl->get_remote_ino();
-  uint64_t pool = dnl->get_remote_d_type() == DT_DIR ? mds->mdsmap->get_metadata_pool() : -1;
+  int64_t pool = dnl->get_remote_d_type() == DT_DIR ? mds->mdsmap->get_metadata_pool() : -1;
   open_ino(ino, pool,
       new C_MDC_OpenRemoteDentry(this, dn, ino, fin, want_xlocked), true, want_xlocked); // backtrace
 }