msi: Return the results from OpenSourceKey.
This commit is contained in:
parent
d37ac289db
commit
fe987103fb
|
@ -81,7 +81,7 @@ static UINT OpenSourceKey(LPCWSTR szProduct, HKEY* key, DWORD dwOptions,
|
||||||
rc = MSIREG_OpenLocalClassesProductKey(szProduct, &rootkey, create);
|
rc = MSIREG_OpenLocalClassesProductKey(szProduct, &rootkey, create);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (rc)
|
if (rc != ERROR_SUCCESS)
|
||||||
{
|
{
|
||||||
if (dwOptions == MSICODE_PATCH)
|
if (dwOptions == MSICODE_PATCH)
|
||||||
return ERROR_UNKNOWN_PATCH;
|
return ERROR_UNKNOWN_PATCH;
|
||||||
|
@ -424,8 +424,7 @@ UINT WINAPI MsiSourceListSetInfoW( LPCWSTR szProduct, LPCWSTR szUserSid,
|
||||||
|
|
||||||
rc = OpenSourceKey(szProduct, &sourcekey, MSICODE_PRODUCT, dwContext, FALSE);
|
rc = OpenSourceKey(szProduct, &sourcekey, MSICODE_PRODUCT, dwContext, FALSE);
|
||||||
if (rc != ERROR_SUCCESS)
|
if (rc != ERROR_SUCCESS)
|
||||||
return ERROR_UNKNOWN_PRODUCT;
|
return rc;
|
||||||
|
|
||||||
|
|
||||||
if (strcmpW(szProperty, INSTALLPROPERTY_MEDIAPACKAGEPATHW) == 0)
|
if (strcmpW(szProperty, INSTALLPROPERTY_MEDIAPACKAGEPATHW) == 0)
|
||||||
{
|
{
|
||||||
|
|
|
@ -1499,11 +1499,8 @@ static void test_MsiSourceListSetInfo(void)
|
||||||
r = MsiSourceListSetInfoA(prodcode, NULL,
|
r = MsiSourceListSetInfoA(prodcode, NULL,
|
||||||
MSIINSTALLCONTEXT_USERUNMANAGED, MSICODE_PRODUCT,
|
MSIINSTALLCONTEXT_USERUNMANAGED, MSICODE_PRODUCT,
|
||||||
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
||||||
todo_wine
|
ok(r == ERROR_BAD_CONFIGURATION,
|
||||||
{
|
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
||||||
ok(r == ERROR_BAD_CONFIGURATION,
|
|
||||||
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
|
||||||
}
|
|
||||||
|
|
||||||
res = RegCreateKeyA(userkey, "SourceList", &source);
|
res = RegCreateKeyA(userkey, "SourceList", &source);
|
||||||
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
||||||
|
@ -1743,11 +1740,8 @@ static void test_MsiSourceListSetInfo(void)
|
||||||
r = MsiSourceListSetInfoA(prodcode, NULL,
|
r = MsiSourceListSetInfoA(prodcode, NULL,
|
||||||
MSIINSTALLCONTEXT_USERMANAGED, MSICODE_PRODUCT,
|
MSIINSTALLCONTEXT_USERMANAGED, MSICODE_PRODUCT,
|
||||||
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
||||||
todo_wine
|
ok(r == ERROR_BAD_CONFIGURATION,
|
||||||
{
|
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
||||||
ok(r == ERROR_BAD_CONFIGURATION,
|
|
||||||
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
|
||||||
}
|
|
||||||
|
|
||||||
res = RegCreateKeyA(userkey, "SourceList", &source);
|
res = RegCreateKeyA(userkey, "SourceList", &source);
|
||||||
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
||||||
|
@ -1789,11 +1783,8 @@ static void test_MsiSourceListSetInfo(void)
|
||||||
r = MsiSourceListSetInfoA(prodcode, NULL,
|
r = MsiSourceListSetInfoA(prodcode, NULL,
|
||||||
MSIINSTALLCONTEXT_MACHINE, MSICODE_PRODUCT,
|
MSIINSTALLCONTEXT_MACHINE, MSICODE_PRODUCT,
|
||||||
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
INSTALLPROPERTY_MEDIAPACKAGEPATH, "path");
|
||||||
todo_wine
|
ok(r == ERROR_BAD_CONFIGURATION,
|
||||||
{
|
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
||||||
ok(r == ERROR_BAD_CONFIGURATION,
|
|
||||||
"Expected ERROR_BAD_CONFIGURATION, got %d\n", r);
|
|
||||||
}
|
|
||||||
|
|
||||||
res = RegCreateKeyA(prodkey, "SourceList", &source);
|
res = RegCreateKeyA(prodkey, "SourceList", &source);
|
||||||
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
ok(res == ERROR_SUCCESS, "Expected ERROR_SUCCESS, got %d\n", res);
|
||||||
|
|
Loading…
Reference in New Issue