]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
vfs_ceph_new: avoid setting errno in cephmount_cache_update
authorShachar Sharon <ssharon@redhat.com>
Wed, 4 Sep 2024 12:59:21 +0000 (15:59 +0300)
committerJule Anger <janger@samba.org>
Mon, 17 Feb 2025 16:09:09 +0000 (16:09 +0000)
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 <ssharon@redhat.com>
Reviewed-by: Anoop C S <anoopcs@samba.org>
Reviewed-by: John Mulligan <jmulligan@redhat.com>
(cherry picked from commit 1f7581c9edb32a2a63bf032f7e167be8a401c3d5)

source3/modules/vfs_ceph_new.c

index e5afac20be169e5f1ea01116d2c55b7a65661300..235cc352d2e72fc88c3af2a0ee876e64a6c2e996 100644 (file)
@@ -220,7 +220,6 @@ static struct cephmount_cached *cephmount_cache_update(const char *cookie)
                }
        }
 
-       errno = ENOENT;
        return NULL;
 }