RAM Search: Fix counting of number of changes.

This commit is contained in:
gocha 2010-08-10 05:22:41 +00:00
parent b2faef8aad
commit f00bdc7b72
1 changed files with 2 additions and 2 deletions

View File

@ -285,11 +285,11 @@ void UpdateRegionT(const MemoryRegion& region, const MemoryRegion* nextRegionPtr
if(i >= indexEnd+k)
continue;
int m = (j-k+sizeof(compareType)) & (sizeof(compareType)-1);
if(nextValidChange[m]+sizeof(compareType) <= i+sizeof(compareType)) // if we didn't already increase the change count for this entry
if(nextValidChange[m] <= i) // if we didn't already increase the change count for this entry
{
//if(s_numChanges[i-k] != 0xFFFF)
buffers->s_numChanges[i-k]++; // increase the change count for this entry
nextValidChange[m] = i+sizeof(compareType); // and remember not to increase it again
nextValidChange[m] = i-k+sizeof(compareType); // and remember not to increase it again
}
}
}