From 8454410c15c1a3b8d589729ec9504c31f68f2955 Mon Sep 17 00:00:00 2001 From: David Disseldorp Date: Wed, 8 Jan 2020 10:51:24 +0100 Subject: [PATCH] client: propagate -ENOTCONN errors for ll_releasedir When initially added via e2dc1b6bf284, the unconditional ceph_ll_releasedir() zero-return doesn't appear to have had any effect, as Client::ll_releasedir() always returned zero. efca340596ef added -ENOTCONN errors when Client::ll_releasedir() is called during unmount. Ensure that this error is propagated. Signed-off-by: David Disseldorp --- src/libcephfs.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/libcephfs.cc b/src/libcephfs.cc index 0ace2c0f620..dab8c2ade0e 100644 --- a/src/libcephfs.cc +++ b/src/libcephfs.cc @@ -1801,8 +1801,7 @@ extern "C" int ceph_ll_opendir(class ceph_mount_info *cmount, extern "C" int ceph_ll_releasedir(class ceph_mount_info *cmount, ceph_dir_result *dir) { - (void) cmount->get_client()->ll_releasedir(reinterpret_cast(dir)); - return (0); + return cmount->get_client()->ll_releasedir(reinterpret_cast(dir)); } extern "C" int ceph_ll_rename(class ceph_mount_info *cmount, -- 2.39.5