diff --git a/src/mds/Server.cc b/src/mds/Server.cc index 5b7222e4dcd..3887faac506 100644 --- a/src/mds/Server.cc +++ b/src/mds/Server.cc @@ -4157,6 +4157,7 @@ void Server::handle_set_vxattr(MDRequestRef& mdr, CInode *cur, return; } + xlocks.insert(&cur->filelock); if (!mds->locker->acquire_locks(mdr, rdlocks, wrlocks, xlocks)) return; @@ -4166,7 +4167,6 @@ void Server::handle_set_vxattr(MDRequestRef& mdr, CInode *cur, } } - xlocks.insert(&cur->filelock); pi = cur->project_inode(); int64_t old_pool = pi->layout.fl_pg_pool; pi->add_old_pool(old_pool);