Merge tag 'ceph-for-5.2-rc7' of git://github.com/ceph/ceph-client
Merge commit. Changes below are compared with the first parent: 5b607ba8.
Changes
1 files changed · +2 −1
| File | Status | Add | Del | Content |
|---|---|---|---|---|
| fs/ceph/mds_client.c | modified | +2 | −1 | View file |
fs/ceph/mds_client.c
View filediff --git a/fs/ceph/mds_client.c b/fs/ceph/mds_client.c
index 6af2d0d..c8a9b89 100644
--- a/fs/ceph/mds_client.c
+++ b/fs/ceph/mds_client.c
@@ -2121,9 +2121,10 @@ retry:
if (inode && ceph_snap(inode) == CEPH_SNAPDIR) {
dout("build_path path+%d: %p SNAPDIR\n",
pos, temp);
- } else if (stop_on_nosnap && inode &&
+ } else if (stop_on_nosnap && inode && dentry != temp &&
ceph_snap(inode) == CEPH_NOSNAP) {
spin_unlock(&temp->d_lock);
+ pos++; /* get rid of any prepended '/' */
break;
} else {
pos -= temp->d_name.len;