--- old/src/java.desktop/macosx/native/libawt_lwawt/font/CGGlyphImages.m 2015-10-06 15:12:42.000000000 +0530 +++ new/src/java.desktop/macosx/native/libawt_lwawt/font/CGGlyphImages.m 2015-10-06 15:12:42.000000000 +0530 @@ -565,12 +565,14 @@ // clean the canvas CGGI_ClearCanvas(canvas, info); + if (isnan(info->topLeftX) || isnan(info->topLeftY)) { + return; + } // strike the glyph in the upper right corner CGContextShowGlyphsAtPoint(canvas->context, -info->topLeftX, canvas->image->height + info->topLeftY, &glyph, 1); - // copy the glyph from the canvas into the info (*mode->glyphDescriptor->copyFxnPtr)(canvas, info); } @@ -855,7 +857,6 @@ CGGI_CreateGlyphsAndScanForComplexities(glyphInfos, strike, &mode, rawGlyphCodes, uniChars, glyphs, advances, bboxes, len); - return; } @@ -875,6 +876,5 @@ CGGI_CreateGlyphsAndScanForComplexities(glyphInfos, strike, &mode, rawGlyphCodes, uniChars, glyphs, advances, bboxes, len); - free(buffer); }