Commit eb1711bf authored by Dmitry Timoshkov's avatar Dmitry Timoshkov Committed by Alexandre Julliard

Use a passed SecurityDescriptor in CreateFileW.

parent 58dcfb62
...@@ -55,6 +55,9 @@ ...@@ -55,6 +55,9 @@
#ifdef HAVE_UTIME_H #ifdef HAVE_UTIME_H
# include <utime.h> # include <utime.h>
#endif #endif
#ifdef HAVE_IO_H
# include <io.h>
#endif
#define NONAMELESSUNION #define NONAMELESSUNION
#define NONAMELESSSTRUCT #define NONAMELESSSTRUCT
...@@ -458,7 +461,7 @@ HANDLE WINAPI CreateFileW( LPCWSTR filename, DWORD access, DWORD sharing, ...@@ -458,7 +461,7 @@ HANDLE WINAPI CreateFileW( LPCWSTR filename, DWORD access, DWORD sharing,
attr.RootDirectory = 0; attr.RootDirectory = 0;
attr.Attributes = OBJ_CASE_INSENSITIVE; attr.Attributes = OBJ_CASE_INSENSITIVE;
attr.ObjectName = &nameW; attr.ObjectName = &nameW;
attr.SecurityDescriptor = NULL; attr.SecurityDescriptor = sa ? sa->lpSecurityDescriptor : NULL;
attr.SecurityQualityOfService = NULL; attr.SecurityQualityOfService = NULL;
if (sa && sa->bInheritHandle) attr.Attributes |= OBJ_INHERIT; if (sa && sa->bInheritHandle) attr.Attributes |= OBJ_INHERIT;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment