1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-26 10:08:06 +02:00

Merge pull request #3882 from yurydelendik/issue3438

Ignoring glyphs without points
This commit is contained in:
Tim van der Meij 2013-11-08 14:21:17 -08:00
commit 6be8a2bd83
4 changed files with 11 additions and 0 deletions

View file

@ -3175,6 +3175,10 @@ var Font = (function FontClosure() {
coordinatesLength += repeat * xyLength;
}
}
// glyph without coordinates will be rejected
if (coordinatesLength === 0) {
return 0;
}
var glyphDataLength = j + coordinatesLength;
if (glyphDataLength > glyf.length) {
// not enough data for coordinates