Paul Vriens wrote:
Hi,
I'm still looking into the fact why the msi.c tests fails for me (and succeeds when running with WINEDEBUG=+msi).
A trace (+msi,+reg,+ole) revealed:
trace:msi:MsiQueryProductStateW L"A938G02JF-2NF3N93-VN3-2NNF-3KGKALDNF93" trace:msi:MSIREG_OpenUserProductsKey L"A938G02JF-2NF3N93-VN3-2NNF-3KGKALDNF93" trace:reg:NtOpenKey (0x48,L"A938G02JF-2NF3N93-VN3-2NNF-3KGKALDNF93\CLSID",f003f,0x34f37c) trace:reg:NtOpenKey <- (nil) warn:ole:CLSIDFromProgID couldn't open key for ProgID L"A938G02JF-2NF3N93-VN3-2NNF-3KGKALDNF93" trace:msi:squash_guid Returning FALSE trace:msi:MSIREG_OpenUserProductsKey squished (L"\7bc9\0480\0011\f8c84\2f47\7bc3\c7ea\7ecd\f9204\7139\7ecf\c89a\7ecd\00ff")
(the 'Returning FALSE' is my doing).
The squished_pc variable in MSIREG_OpenUserProductsKey is filled with garbage.
I think that we should patch msi/registry.c:
diff --git a/dlls/msi/registry.c b/dlls/msi/registry.c index b9c0af4..24a3def 100644 --- a/dlls/msi/registry.c +++ b/dlls/msi/registry.c @@ -233,6 +233,8 @@ BOOL squash_guid(LPCWSTR in, LPWSTR out) DWORD i,n=1; GUID guid;
- out[0] = 0;
- if (FAILED(CLSIDFromString((LPOLESTR)in, &guid))) return FALSE;
So 'out' is always clean at the start. Adding this patch makes the test fail consistently :-). So it's not the fix.
Any comments/remarks/suggestions ?
Cheers,
Paul.
Another question about squash_guid. Why does it return a BOOL but that information is not used by any of the callers?
Should we both patch squash_guid (to at least no return garbage) and change all the callers to bail out if squash_guid failed?
Cheers,
Paul.