vfs_fruit: only do cross protocol locking on non-internal opens
authorRalph Boehme <slow@samba.org>
Thu, 23 May 2019 14:22:39 +0000 (16:22 +0200)
committerJeremy Allison <jra@samba.org>
Thu, 30 May 2019 20:19:27 +0000 (20:19 +0000)
Bug: https://bugzilla.samba.org/show_bug.cgi?id=13968

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

index 128ad4bd227334764d97564700a58c8fe46f5391..cce530bbc9761124eae6d3bd22ce3075efa70d68 100644 (file)
@@ -6094,7 +6094,9 @@ static NTSTATUS fruit_create_file(vfs_handle_struct *handle,
                return status;
        }
 
-       if (config->locking == FRUIT_LOCKING_NETATALK) {
+       if ((config->locking == FRUIT_LOCKING_NETATALK) &&
+           (fsp->op != NULL))
+       {
                status = fruit_check_access(
                        handle, *result,
                        access_mask,