Commit f49cb52c authored by Huw D M Davies's avatar Huw D M Davies Committed by Alexandre Julliard

Fix save_check_tainted to properly scan the tree so that all tainted

branches get saved.
parent 8eec66b2
......@@ -533,7 +533,7 @@ static void split_keypath( LPCWSTR wp, LPWSTR **wpv, int *wpc)
for (i=1;i<len;i++)
if (ws[i-1]==0) {
(*wpv)[j++]=ws+i;
/* TRACE(reg, " Subitem %d = %s\n",j-1,debugstr_w((*wpv)[j-1])); */
/*TRACE_(reg) (" Subitem %d = %s\n",j-1,debugstr_w((*wpv)[j-1]));*/
}
(*wpv)[j]=NULL;
......@@ -618,19 +618,13 @@ static void REGISTRY_Init(void) {
*/
static int _save_check_tainted( LPKEYSTRUCT lpkey )
{
int tainted;
int tainted = 0;
if (!lpkey)
return 0;
if (lpkey->flags & REG_OPTION_TAINTED)
tainted = 1;
else
tainted = 0;
while (lpkey) {
if (_save_check_tainted(lpkey->nextsub)) {
if (_save_check_tainted(lpkey->nextsub))
lpkey->flags |= REG_OPTION_TAINTED;
if (lpkey->flags & REG_OPTION_TAINTED)
tainted = 1;
}
lpkey = lpkey->next;
}
return tainted;
......
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