From a8e3a1bdabe71eea54fbec2ccfe189561bcde283 Mon Sep 17 00:00:00 2001 From: Thomas Faber Date: Tue, 24 Nov 2015 14:57:00 +0000 Subject: [PATCH] [MSI] - Use the correct attributes when overwriting a read-only file in cabinet_copy_file. Will be sent upstream after the 1.8 release. CORE-10534 #resolve svn path=/trunk/; revision=70095 --- reactos/dll/win32/msi/media.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/reactos/dll/win32/msi/media.c b/reactos/dll/win32/msi/media.c index e7f24c4f6d9..c975f73b923 100644 --- a/reactos/dll/win32/msi/media.c +++ b/reactos/dll/win32/msi/media.c @@ -465,7 +465,7 @@ static INT_PTR cabinet_copy_file(FDINOTIFICATIONTYPE fdint, { TRACE("removing read-only attribute on %s\n", debugstr_w(path)); SetFileAttributesW( path, attrs2 & ~FILE_ATTRIBUTE_READONLY ); - handle = CreateFileW(path, GENERIC_READ | GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, attrs2, NULL); + handle = CreateFileW(path, GENERIC_READ | GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, attrs, NULL); if (handle != INVALID_HANDLE_VALUE) goto done; err = GetLastError(); -- 2.17.1