From: Shachar Sharon Date: Wed, 4 Sep 2024 12:59:21 +0000 (+0300) Subject: vfs_ceph_new: avoid setting errno in cephmount_cache_update X-Git-Tag: samba-4.21.4~18 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=79d6da01caa55a978fdb7d023c2347a7503641c2;p=thirdparty%2Fsamba.git vfs_ceph_new: avoid setting errno in cephmount_cache_update Do not set 'errno' to ENOENT in cephmount_cache_update. Setting this errno value upon newly inserted entry may cause vfs_ceph_connect to change errno to non-zero value even though the final result is OK. BUG: https://bugzilla.samba.org/show_bug.cgi?id=15703 Signed-off-by: Shachar Sharon Reviewed-by: Anoop C S Reviewed-by: John Mulligan (cherry picked from commit 1f7581c9edb32a2a63bf032f7e167be8a401c3d5) --- diff --git a/source3/modules/vfs_ceph_new.c b/source3/modules/vfs_ceph_new.c index e5afac20be1..235cc352d2e 100644 --- a/source3/modules/vfs_ceph_new.c +++ b/source3/modules/vfs_ceph_new.c @@ -220,7 +220,6 @@ static struct cephmount_cached *cephmount_cache_update(const char *cookie) } } - errno = ENOENT; return NULL; }