Skip to content
Snippets Groups Projects
Commit bd9d8a32 authored by Michael McCormack's avatar Michael McCormack Committed by Alexandre Julliard
Browse files

MsiOpenDatabase's szPersist parameter may be a string or a bitmask.

parent 16ff6689
No related branches found
No related tags found
No related merge requests found
......@@ -149,7 +149,7 @@ UINT WINAPI MsiOpenDatabaseA(
MultiByteToWideChar( CP_ACP, 0, szDBPath, -1, szwDBPath, len );
}
if( szPersist )
if( HIWORD(szPersist) )
{
len = MultiByteToWideChar( CP_ACP, 0, szPersist, -1, NULL, 0 );
szwPersist = HeapAlloc( GetProcessHeap(), 0, len * sizeof(WCHAR) );
......@@ -157,6 +157,8 @@ UINT WINAPI MsiOpenDatabaseA(
goto end;
MultiByteToWideChar( CP_ACP, 0, szPersist, -1, szwPersist, len );
}
else
szwPersist = (LPWSTR) szPersist;
r = MsiOpenDatabaseW( szwDBPath, szwPersist, phDB );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment