aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorErlang/OTP <[email protected]>2010-06-02 11:27:01 +0000
committerErlang/OTP <[email protected]>2010-06-02 11:27:01 +0000
commit1ac35cc337f3e9bfdd6a0c64cb089a088811feca (patch)
treee498fabd01c38715e4d79e4b4ce30074c60c0c36
parente2d2e03227b6e910ba4f8ba5a16e5a8bb2a3d38e (diff)
parent426a5e21ab8306517ecd6d73f253d8dc13e39925 (diff)
downloadotp-1ac35cc337f3e9bfdd6a0c64cb089a088811feca.tar.gz
otp-1ac35cc337f3e9bfdd6a0c64cb089a088811feca.tar.bz2
otp-1ac35cc337f3e9bfdd6a0c64cb089a088811feca.zip
Merge branch 'jl/windows-file-share-delete' into dev
* jl/windows-file-share-delete: Windows: Open files with FILE_SHARE_DELETE to get closer to UNIX semantics OTP-8667 jl/windows-file-share-delete On Windows, files are now opened with FILE_SHARE_DELETE to get closer to Unix semantics.
-rw-r--r--erts/emulator/drivers/win32/win_efile.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/erts/emulator/drivers/win32/win_efile.c b/erts/emulator/drivers/win32/win_efile.c
index d5f2b79706..24b6fb30dc 100644
--- a/erts/emulator/drivers/win32/win_efile.c
+++ b/erts/emulator/drivers/win32/win_efile.c
@@ -689,7 +689,8 @@ Sint64* pSize; /* Where to store the size of the file. */
if (flags & EFILE_MODE_APPEND) {
crFlags = OPEN_ALWAYS;
}
- fd = CreateFile(name, access, FILE_SHARE_READ | FILE_SHARE_WRITE,
+ fd = CreateFile(name, access,
+ FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE,
NULL, crFlags, FILE_ATTRIBUTE_NORMAL, NULL);
/*