captive_directory_new_internal(): Allow also READ/WRITE directory sharing
authorshort <>
Mon, 3 Feb 2003 14:31:22 +0000 (14:31 +0000)
committershort <>
Mon, 3 Feb 2003 14:31:22 +0000 (14:31 +0000)
 - needed to move files into an open directory

src/libcaptive/client/directory.c

index 8fdbad7..5c78cf5 100644 (file)
@@ -120,7 +120,7 @@ CaptiveDirectoryObject *captive_directory_object;
                        &dir_IoStatusBlock,     /* IoStatusBlock */
                        NULL,   /* AllocationSize; ignored for open */
                        (!create || create_perm&0200 ? FILE_ATTRIBUTE_NORMAL: FILE_ATTRIBUTE_READONLY), /* FileAttributes; ignored for open */
-                       FILE_SHARE_DELETE,      /* ShareAccess; 0 means exclusive */
+                       (FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE),       /* ShareAccess; 0 means exclusive */
                        (!create ? FILE_OPEN : FILE_CREATE),    /* CreateDisposition */
                        /* FILE_SYNCHRONOUS_IO_{,NON}ALERT: We need to allow W32 filesystem
                         * any waits to not to let it return STATUS_CANT_WAIT us.