changeset 6151:d54db1e16b97

7124223: [macosx] Regression test failure with new exception, when glyph is positioned explicitly Reviewed-by: jgodinez
author bae
date Fri, 30 Nov 2012 11:32:36 +0400
parents 934595726263
children bd3b3cda125d
files src/share/classes/sun/print/PathGraphics.java
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/share/classes/sun/print/PathGraphics.java	Wed Nov 28 14:12:32 2012 +0400
+++ b/src/share/classes/sun/print/PathGraphics.java	Fri Nov 30 11:32:36 2012 +0400
@@ -1025,7 +1025,8 @@
                 continue;
             }
             glyph = font2D.charToGlyph(c);
-            if (glyph != missingGlyph && glyph < numGlyphs &&
+            if (glyph != missingGlyph &&
+                glyph >= 0 && glyph < numGlyphs &&
                 (glyphToCharMap[glyph] ==
                  CharToGlyphMapper.INVISIBLE_GLYPH_ID)) {
                 glyphToCharMap[glyph] = c;