From 464afaa2c98c2c1d0db68c1e3f6b60de4beaed5b Mon Sep 17 00:00:00 2001 From: Xiubo Li Date: Mon, 9 Oct 2023 12:15:02 +0800 Subject: [PATCH] client: return false if cannot link all the way to mountpoint Just in case we cannot link all the way to our mount point we will force to do sync requests instead and let the MDS do the auth access check. Introduced-by: fd7aaab2907 client: add make_path_string() helpers support Fixes: https://github.com/ceph/ceph/pull/48027#issuecomment-1752324457 Signed-off-by: Xiubo Li (cherry picked from commit c7bc4523ffec65d132eef217ce87eaf344144e35) --- src/client/Dentry.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/client/Dentry.h b/src/client/Dentry.h index c66aca6f1e0..47d320ecbbc 100644 --- a/src/client/Dentry.h +++ b/src/client/Dentry.h @@ -84,7 +84,8 @@ public: if (dir) { ret = dir->parent_inode->make_path_string(s); } else { - s = "???"; + // Couldn't link all the way to our mount point + return false; } s += "/"; s.append(name.data(), name.length()); -- 2.39.5