Commit c90c781a authored by Mike McCormack's avatar Mike McCormack Committed by Alexandre Julliard

Implement MsiVerifyPackage, cosmetic fixes.

parent b7408909
......@@ -3026,7 +3026,7 @@ static UINT ACTION_InstallInitialize(MSIPACKAGE *package)
}
/*
* components FeatureState defaults to FALSE. the idea is we want to
* Components FeatureState defaults to FALSE. The idea is we want to
* enable the component is ANY feature that uses it is enabled to install
*/
for(i = 0; i < package->loaded_features; i++)
......@@ -3053,7 +3053,7 @@ static UINT ACTION_InstallInitialize(MSIPACKAGE *package)
if (override != NULL)
HeapFree(GetProcessHeap(),0,override);
/*
* so basically we ONLY want to install a component if its Enabled AND
* So basically we ONLY want to install a component if its Enabled AND
* FeatureState are both TRUE
*/
return ERROR_SUCCESS;
......@@ -3306,10 +3306,10 @@ end:
static UINT ACTION_RegisterTypeLibraries(MSIPACKAGE *package)
{
/*
* ok this is a bit confusting.. I am given a _Component key and i believe
* OK this is a bit confusing.. I am given a _Component key and I believe
* that the file that is being registered as a type library is the "key file
* of that component" which i interpert to mean "The file in the KeyPath of
* that component"
* of that component" which I interpret to mean "The file in the KeyPath of
* that component".
*/
UINT rc;
MSIQUERY * view;
......@@ -3391,8 +3391,8 @@ static UINT ACTION_RegisterTypeLibraries(MSIPACKAGE *package)
debugstr_w(package->files[index].TargetPath));
else
{
/* yes the row has more fields than i need, but #1 is
correct and the only one i need. why make a new row */
/* Yes the row has more fields than I need, but #1 is
correct and the only one I need. Why make a new row? */
ui_actiondata(package,szRegisterTypeLibraries,row);
......@@ -3536,8 +3536,8 @@ static UINT register_appid(MSIPACKAGE *package, LPCWSTR clsid, LPCWSTR app )
static UINT ACTION_RegisterClassInfo(MSIPACKAGE *package)
{
/*
* Again I am assuming the words, "Whose key file respesents" when refering
* to a Component as to mean the Components KeyPath file
* Again I am assuming the words, "Whose key file represents" when refering
* to a Component as to meaning that Components KeyPath file
*
* Also there is a very strong connection between ClassInfo and ProgID
* that I am mostly glossing over.
......@@ -3814,12 +3814,12 @@ static UINT register_progid(MSIPACKAGE *package, MSIRECORD * row, LPWSTR clsid)
static UINT ACTION_RegisterProgIdInfo(MSIPACKAGE *package)
{
/*
* Sigh, here i am just brute force registering all progid
* Sigh, here I am just brute force registering all progids
* this needs to be linked to the Classes that have been registerd
* but the easiest way to do that is to load all these stuff into
* memory for easy checking.
*
* gives me something to continue to work toward
* Gives me something to continue to work toward.
*/
UINT rc;
MSIQUERY * view;
......
......@@ -57,8 +57,6 @@ struct cond_str {
static LPWSTR COND_GetString( struct cond_str *str );
static int COND_lex( void *COND_lval, COND_input *info);
UINT get_property(MSIHANDLE hPackage, const WCHAR* prop, WCHAR* value,
DWORD* size);
typedef INT (*comp_int)(INT a, INT b);
typedef INT (*comp_str)(LPWSTR a, LPWSTR b, BOOL caseless);
......
......@@ -1180,14 +1180,38 @@ UINT WINAPI MsiGetProductPropertyW( MSIHANDLE hProduct, LPCWSTR szProperty,
UINT WINAPI MsiVerifyPackageA( LPCSTR szPackage )
{
FIXME("%s\n", debugstr_a(szPackage) );
return ERROR_CALL_NOT_IMPLEMENTED;
UINT r, len;
LPWSTR szPack = NULL;
TRACE("%s\n", debugstr_a(szPackage) );
if( szPackage )
{
len = MultiByteToWideChar( CP_ACP, 0, szPackage, -1, NULL, 0 );
szPack = HeapAlloc( GetProcessHeap(), 0, len*sizeof(WCHAR) );
if( !szPack )
return ERROR_OUTOFMEMORY;
MultiByteToWideChar( CP_ACP, 0, szPackage, -1, szPack, len );
}
r = MsiVerifyPackageW( szPack );
HeapFree( GetProcessHeap(), 0, szPack );
return r;
}
UINT WINAPI MsiVerifyPackageW( LPCWSTR szPackage )
{
FIXME("%s\n", debugstr_w(szPackage) );
return ERROR_CALL_NOT_IMPLEMENTED;
MSIHANDLE handle;
UINT r;
TRACE("%s\n", debugstr_w(szPackage) );
r = MsiOpenDatabaseW( szPackage, MSIDBOPEN_READONLY, &handle );
MsiCloseHandle( handle );
return r;
}
INSTALLSTATE WINAPI MsiGetComponentPathA(LPCSTR szProduct, LPCSTR szComponent,
......
......@@ -254,7 +254,7 @@ static VOID set_installer_properties(MSIPACKAGE *package)
'D','e','s','k','t','o','p','\\',0};
/*
* Other things i notice set
* Other things I notice set
*
ScreenY
ScreenX
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment