From: Greg Farnum Date: Thu, 12 May 2011 22:43:23 +0000 (-0700) Subject: uclient: compare _revoked_ caps when deciding whether to release. X-Git-Tag: v0.29~118 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=84644dc56183b67050793a1b8da07850508b29d6;p=ceph.git uclient: compare _revoked_ caps when deciding whether to release. cap->issued is already set to new_caps, so that branch was never taken! Signed-off-by: Greg Farnum --- diff --git a/src/client/Client.cc b/src/client/Client.cc index 629816c78a4c..eec9253f3b32 100644 --- a/src/client/Client.cc +++ b/src/client/Client.cc @@ -2935,7 +2935,7 @@ void Client::handle_cap_grant(Inode *in, int mds, InodeCap *cap, MClientCaps *m) dout(10) << " revocation of " << ccap_string(~new_caps & old_caps) << dendl; cap->issued = new_caps; - if ((cap->issued & ~new_caps) & CEPH_CAP_FILE_CACHE) + if ((cap->issued & ~old_caps) & CEPH_CAP_FILE_CACHE) _release(in, false); if ((used & ~new_caps) & CEPH_CAP_FILE_BUFFER)