Fix save_check_tainted to properly scan the tree so that all tainted
branches get saved.
This commit is contained in:
parent
8eec66b213
commit
f49cb52c69
|
@ -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;
|
||||
while (lpkey) {
|
||||
if (_save_check_tainted(lpkey->nextsub))
|
||||
lpkey->flags |= REG_OPTION_TAINTED;
|
||||
if (lpkey->flags & REG_OPTION_TAINTED)
|
||||
tainted = 1;
|
||||
else
|
||||
tainted = 0;
|
||||
while (lpkey) {
|
||||
if (_save_check_tainted(lpkey->nextsub)) {
|
||||
lpkey->flags |= REG_OPTION_TAINTED;
|
||||
tainted = 1;
|
||||
}
|
||||
lpkey = lpkey->next;
|
||||
}
|
||||
return tainted;
|
||||
|
|
Loading…
Reference in New Issue