summaryrefslogtreecommitdiff
path: root/stdlib/headernt.c
diff options
context:
space:
mode:
Diffstat (limited to 'stdlib/headernt.c')
-rw-r--r--stdlib/headernt.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/stdlib/headernt.c b/stdlib/headernt.c
index 5244431b48..288e2ae1b0 100644
--- a/stdlib/headernt.c
+++ b/stdlib/headernt.c
@@ -70,7 +70,8 @@ int main(int argc, char ** argv)
int retcode;
GetModuleFileName(NULL, truename, sizeof(truename));
- h = CreateFile(truename, GENERIC_READ, 0, NULL, OPEN_EXISTING, 0, NULL);
+ h = CreateFile(truename, GENERIC_READ, FILE_SHARE_READ | FILE_SHARE_WRITE,
+ NULL, OPEN_EXISTING, 0, NULL);
if (h == INVALID_HANDLE_VALUE ||
(runtime_path = read_runtime_path(h)) == NULL) {
errwrite(truename);