Implement the functionality that allows one to call MsiOpenPackage
with #nnn where nnn is a string representing the handle to an open database.
This commit is contained in:
parent
433b5d416f
commit
9c76b14469
|
@ -378,9 +378,17 @@ UINT MSI_OpenPackageW(LPCWSTR szPackage, MSIPACKAGE **pPackage)
|
|||
|
||||
TRACE("%s %p\n",debugstr_w(szPackage), pPackage);
|
||||
|
||||
if (szPackage[0] == '#')
|
||||
{
|
||||
INT handle = atoiW(&szPackage[1]);
|
||||
db = msihandle2msiinfo( handle , MSIHANDLETYPE_DATABASE);
|
||||
}
|
||||
else
|
||||
{
|
||||
rc = MSI_OpenDatabaseW(szPackage, MSIDBOPEN_READONLY, &db);
|
||||
if (rc != ERROR_SUCCESS)
|
||||
return ERROR_FUNCTION_FAILED;
|
||||
}
|
||||
|
||||
package = alloc_msiobject( MSIHANDLETYPE_PACKAGE, sizeof (MSIPACKAGE),
|
||||
MSI_FreePackage );
|
||||
|
|
Loading…
Reference in New Issue