зеркало из https://github.com/mozilla/pjs.git
Bug 534352. Accept fonts with redundant cmap sentinel value. r=jdaggett
This commit is contained in:
Родитель
21162668eb
Коммит
0ef0c8f49d
|
@ -317,13 +317,13 @@ gfxFontUtils::ReadCMAPTableFormat4(PRUint8 *aBuf, PRUint32 aLength, gfxSparseBit
|
|||
const PRUint16 endCount = ReadShortAt16(endCounts, i);
|
||||
const PRUint16 startCount = ReadShortAt16(startCounts, i);
|
||||
const PRUint16 idRangeOffset = ReadShortAt16(idRangeOffsets, i);
|
||||
|
||||
|
||||
// sanity-check range
|
||||
NS_ENSURE_TRUE((startCount > prevEndCount || i == 0) &&
|
||||
NS_ENSURE_TRUE((startCount > prevEndCount || i == 0 || startCount == 0xFFFF) &&
|
||||
startCount <= endCount,
|
||||
NS_ERROR_GFX_CMAP_MALFORMED);
|
||||
prevEndCount = endCount;
|
||||
|
||||
|
||||
if (idRangeOffset == 0) {
|
||||
aCharacterMap.SetRange(startCount, endCount);
|
||||
} else {
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
<html>
|
||||
<head>
|
||||
<style type="text/css">
|
||||
body {
|
||||
font-family: serif;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
This should NOT be in the default serif font.
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,19 @@
|
|||
<html>
|
||||
<head>
|
||||
<!-- font Prototype.ttf (see bug 496573 comment #25 and bug 534352)
|
||||
has a redundant [0xFFFF,0xFFFF] sentinel value in the cmap -->
|
||||
<style type="text/css">
|
||||
@font-face {
|
||||
font-family: test;
|
||||
src: url(../fonts/Prototype.ttf);
|
||||
}
|
||||
|
||||
body {
|
||||
font-family: test, serif;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
This should NOT be in the default serif font.
|
||||
</body>
|
||||
</html>
|
|
@ -118,3 +118,6 @@ HTTP(..) != 507960-1-woff-bad-hint.html 507960-1-ref.html
|
|||
HTTP(..) == underline-offset-change-1.html underline-offset-change-1-ref.html
|
||||
HTTP(..) == underline-offset-change-2.html underline-offset-change-2-ref.html
|
||||
fails-if(MOZ_WIDGET_TOOLKIT=="cocoa") fails-if(MOZ_WIDGET_TOOLKIT=="windows") HTTP(..) != underline-offset-change-1-ref.html underline-offset-change-2-ref.html # Bug 534132
|
||||
|
||||
# Bug 534352
|
||||
HTTP(..) != 534352-1-extra-cmap-sentinel.html 534352-1-extra-cmap-sentinel-ref.html
|
||||
|
|
Двоичный файл не отображается.
Загрузка…
Ссылка в новой задаче