mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 10:41:12 +00:00
MsiOpenDatabase's szPersist parameter may be a string or a bitmask.
This commit is contained in:
parent
16ff6689df
commit
bd9d8a32e4
1 changed files with 3 additions and 1 deletions
|
@ -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 );
|
||||
|
||||
|
|
Loading…
Reference in a new issue