https://bugs.documentfoundation.org/show_bug.cgi?id=96518
Bug ID: 96518
Summary: MSI Installer: Test for existing non-empty directory
(CheckInstallDirectory) will always return OK
Product: LibreOffice
Version: Inherited From OOo
Hardware: All
OS: Windows (All)
Status: UNCONFIRMED
Severity: normal
Priority: medium
Component: Installation
Assignee: [email protected]
Reporter: [email protected]
One of our custom install functions CheckInstallDirectory (in Library_shlxtmsi,
compiled from
setup_native/source/win32/customactions/shellextensions/checkdirectory.cxx)
will always claim that the target installation directory is empty, and
therefore OK to install into, as it is checking for the wrong file.
It does this as it inserts the string "LibreOffice 5" between the actual
install location and the file it's trying to test for.
Spotted this whilst looking to eliminate _tstring/TCHAR and Win32 ANSI API
calls.
Verified by adding debug output to this custom installer DLL in a build of 5.1
beta2 and forcing LO install into a differently named directory containing a
program\setup.ini file.
git diff \
-r 4dd1fa636a7408ba04777435911f8b1cb5da7587 \
-r d5c1f2e15d2b80346f02612919dc5de014153bb8 \
setup_native/source/win32/customactions/shellextensions/checkdirectory.cxx
- std::_tstring sSetupIniPath = sInstallPath + TEXT("program\\setup.ini");
+ std::_tstring sSetupIniPath = sInstallPath + sOfficeHostnamePath +
TEXT("\\program\\setup.ini");
*** BUT the worst thing is that this function is called too late in the MSI
InstallExecuteSequence AFTER all the files have been copied anyway, so it would
end up testing for a file which always DID exist...
I think that the best thing to do is to actually eliminate this function from
the installer.
--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs