mirror of
https://github.com/ziglang/zig.git
synced 2026-02-21 00:35:10 +00:00
Fix file locking on windows
The share_access bitfield was being ORed with what was supposed to be parts of the default value, meaning that the share_access would be more permissive than expected.
This commit is contained in:
parent
71c5aab3e7
commit
117d15ed7a
@ -136,7 +136,7 @@ pub fn OpenFileW(
|
||||
.SecurityQualityOfService = null,
|
||||
};
|
||||
var io: IO_STATUS_BLOCK = undefined;
|
||||
const share_access = share_access_opt orelse FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE;
|
||||
const share_access = share_access_opt orelse (FILE_SHARE_WRITE | FILE_SHARE_READ | FILE_SHARE_DELETE);
|
||||
|
||||
var delay: usize = 1;
|
||||
while (true) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user