]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
smbd: check for pathref fd's in vfs_set_blocking()
authorRalph Boehme <slow@samba.org>
Mon, 26 Oct 2020 13:39:02 +0000 (14:39 +0100)
committerRalph Boehme <slow@samba.org>
Wed, 16 Dec 2020 09:08:30 +0000 (09:08 +0000)
Don't try to set pathref fd's to non-blocking, they're not used with IO.

Signed-off-by: Ralph Boehme <slow@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
source3/smbd/vfs.c

index c972c97b7bcb49f91441f4f19ca735866413b0b0..3e30805b6907dd7c4fba8f886370cb267f07bf50 100644 (file)
@@ -794,6 +794,11 @@ int vfs_set_blocking(files_struct *fsp, bool set)
 #define FLAG_TO_SET FNDELAY
 #endif
 #endif
+
+       if (fsp->fsp_flags.is_pathref) {
+               return 0;
+       }
+
        val = SMB_VFS_FCNTL(fsp, F_GETFL, 0);
        if (val == -1) {
                return -1;