mirror of
https://github.com/ceph/ceph
synced 2025-01-03 17:42:36 +00:00
mds: non-head requests always rdlock as_anon
This ensures we can't do a snapped GETATTR and rdlock with EXCL on a directory and miss out on cap metadata still with the client.
This commit is contained in:
parent
1fba876f4f
commit
4a4d68738e
@ -754,6 +754,9 @@ bool Locker::rdlock_start(SimpleLock *lock, MDRequest *mut, bool as_anon)
|
||||
dout(7) << "rdlock_start on " << *lock << " on " << *lock->get_parent() << dendl;
|
||||
|
||||
// client may be allowed to rdlock the same item it has xlocked.
|
||||
// UNLESS someone passes in as_anon, or we're reading snapped version here.
|
||||
if (mut->snapid != CEPH_NOSNAP)
|
||||
as_anon = true;
|
||||
client_t client = as_anon ? -1 : mut->get_client();
|
||||
|
||||
if (!lock->get_parent()->is_auth() &&
|
||||
|
Loading…
Reference in New Issue
Block a user