[msi]
authorMichael Martin <michael.martin@reactos.org>
Fri, 30 Oct 2009 12:53:19 +0000 (12:53 +0000)
committerMichael Martin <michael.martin@reactos.org>
Fri, 30 Oct 2009 12:53:19 +0000 (12:53 +0000)
- Schedule a rename operation also for ERROR_USER_MAPPED_FILE. Prevents msi from aborting an install when attempting to overwrite font files. Open Office should now install successfully.

svn path=/trunk/; revision=43845

reactos/dll/win32/msi/files.c
reactos/dll/win32/msi/media.c

index d9470df..381ceca 100644 (file)
@@ -155,7 +155,7 @@ static UINT copy_install_file(MSIPACKAGE *package, MSIFILE *file, LPWSTR source)
         gle = copy_file(file, source);
         TRACE("Overwriting existing file: %d\n", gle);
     }
         gle = copy_file(file, source);
         TRACE("Overwriting existing file: %d\n", gle);
     }
-    if (gle == ERROR_SHARING_VIOLATION)
+    if ((gle == ERROR_SHARING_VIOLATION) || (gle == ERROR_USER_MAPPED_FILE))
     {
         WCHAR tmpfileW[MAX_PATH], *pathW, *p;
         DWORD len;
     {
         WCHAR tmpfileW[MAX_PATH], *pathW, *p;
         DWORD len;
index 06f14e0..0ec76bd 100644 (file)
@@ -353,7 +353,7 @@ static INT_PTR cabinet_copy_file(FDINOTIFICATIONTYPE fdint,
             if (handle != INVALID_HANDLE_VALUE) goto done;
             err = GetLastError();
         }
             if (handle != INVALID_HANDLE_VALUE) goto done;
             err = GetLastError();
         }
-        if (err == ERROR_SHARING_VIOLATION)
+        if ((err == ERROR_SHARING_VIOLATION) || (err == ERROR_USER_MAPPED_FILE))
         {
             WCHAR tmpfileW[MAX_PATH], *tmppathW, *p;
             DWORD len;
         {
             WCHAR tmpfileW[MAX_PATH], *tmppathW, *p;
             DWORD len;