Module: wine Branch: master Commit: 0de574b258b86c1399af5a53485280e4eb8b7952 URL: http://source.winehq.org/git/wine.git/?a=commit;h=0de574b258b86c1399af5a5348...
Author: James Hawkins truiken@gmail.com Date: Thu May 10 00:02:50 2007 -0500
msi: Deformat the key path before opening the key.
---
dlls/msi/appsearch.c | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/dlls/msi/appsearch.c b/dlls/msi/appsearch.c index 4c5847e..ea2f7cf 100644 --- a/dlls/msi/appsearch.c +++ b/dlls/msi/appsearch.c @@ -244,6 +244,7 @@ static UINT ACTION_AppSearchReg(MSIPACKAGE *package, LPWSTR *appValue, MSISIGNAT 'w','h','e','r','e',' ', 'S','i','g','n','a','t','u','r','e','_',' ','=',' ', ''','%','s',''',0}; LPWSTR keyPath = NULL, valueName = NULL; + LPWSTR deformatted = NULL; int root, type; HKEY rootKey, key = NULL; DWORD sz = 0, regType; @@ -264,11 +265,11 @@ static UINT ACTION_AppSearchReg(MSIPACKAGE *package, LPWSTR *appValue, MSISIGNAT
root = MSI_RecordGetInteger(row,2); keyPath = msi_dup_record_field(row,3); - /* FIXME: keyPath needs to be expanded for properties */ valueName = msi_dup_record_field(row,4); - /* FIXME: valueName probably does too */ type = MSI_RecordGetInteger(row,5);
+ deformat_string(package, keyPath, &deformatted); + switch (root) { case msidbRegistryRootClassesRoot: @@ -288,7 +289,7 @@ static UINT ACTION_AppSearchReg(MSIPACKAGE *package, LPWSTR *appValue, MSISIGNAT goto end; }
- rc = RegOpenKeyW(rootKey, keyPath, &key); + rc = RegOpenKeyW(rootKey, deformatted, &key); if (rc) { TRACE("RegOpenKeyW returned %d\n", rc); @@ -337,6 +338,7 @@ end:
msi_free( keyPath ); msi_free( valueName ); + msi_free( deformatted );
msiobj_release(&row->hdr);