Fix call to CreateFile2.
GitOrigin-RevId: 71fad1b8484402e997b07641552205894d0e1c3e
This commit is contained in:
parent
527c88ca88
commit
78dd033988
@ -198,6 +198,8 @@ Result<FileFd> FileFd::open(CSlice filepath, int32 flags, int32 mode) {
|
|||||||
#else
|
#else
|
||||||
CREATEFILE2_EXTENDED_PARAMETERS extended_parameters;
|
CREATEFILE2_EXTENDED_PARAMETERS extended_parameters;
|
||||||
std::memset(&extended_parameters, 0, sizeof(extended_parameters));
|
std::memset(&extended_parameters, 0, sizeof(extended_parameters));
|
||||||
|
extended_parameters.dwSize = sizeof(extended_parameters);
|
||||||
|
extended_parameters.dwFileAttributes = FILE_ATTRIBUTE_NORMAL;
|
||||||
extended_parameters.dwFileFlags = native_flags;
|
extended_parameters.dwFileFlags = native_flags;
|
||||||
auto handle = CreateFile2(w_filepath.c_str(), desired_access, share_mode, creation_disposition, &extended_parameters);
|
auto handle = CreateFile2(w_filepath.c_str(), desired_access, share_mode, creation_disposition, &extended_parameters);
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
x
Reference in New Issue
Block a user