зеркало из https://github.com/mozilla/pjs.git
Bug 394384. Fix accounting error when tracking the number of times a textrun is referenced from the word cache. debug-only. r+a=pavlov
This commit is contained in:
Родитель
507e95e461
Коммит
420d80a301
|
@ -243,9 +243,6 @@ TextRunWordCache::LookupWord(gfxTextRun *aTextRun, gfxFont *aFirstFont,
|
||||||
if (fontEntry->mTextRun) {
|
if (fontEntry->mTextRun) {
|
||||||
existingEntry = fontEntry;
|
existingEntry = fontEntry;
|
||||||
} else {
|
} else {
|
||||||
#ifdef DEBUG
|
|
||||||
++aTextRun->mCachedWords;
|
|
||||||
#endif
|
|
||||||
PR_LOG(gWordCacheLog, PR_LOG_DEBUG, ("%p(%d-%d,%d): added using font", aTextRun, aStart, aEnd - aStart, aHash));
|
PR_LOG(gWordCacheLog, PR_LOG_DEBUG, ("%p(%d-%d,%d): added using font", aTextRun, aStart, aEnd - aStart, aHash));
|
||||||
key.mFontOrGroup = aTextRun->GetFontGroup();
|
key.mFontOrGroup = aTextRun->GetFontGroup();
|
||||||
CacheHashEntry *groupEntry = mCache.GetEntry(key);
|
CacheHashEntry *groupEntry = mCache.GetEntry(key);
|
||||||
|
@ -273,6 +270,9 @@ TextRunWordCache::LookupWord(gfxTextRun *aTextRun, gfxFont *aFirstFont,
|
||||||
return PR_TRUE;
|
return PR_TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef DEBUG
|
||||||
|
++aTextRun->mCachedWords;
|
||||||
|
#endif
|
||||||
// Set up the cache entry so that if later in this textrun we hit this
|
// Set up the cache entry so that if later in this textrun we hit this
|
||||||
// entry, we'll copy within our own textrun
|
// entry, we'll copy within our own textrun
|
||||||
fontEntry->mTextRun = aTextRun;
|
fontEntry->mTextRun = aTextRun;
|
||||||
|
|
Загрузка…
Ссылка в новой задаче