diablo 1.5 crash
Kurt Miller
lists at intricatesoftware.com
Wed Jul 19 16:16:49 UTC 2006
On Tuesday 18 July 2006 9:59 pm, Kurt Miller wrote:
> On Saturday 15 July 2006 5:40 pm, Jan Zach wrote:
> > I was experimenting a bit and found the problematic font -
> > it is x11-fonts/freefonts package
>
> Thanks. I was able to reproduce the crash here. I don't
> know much about fonts, but I've determined that the
> Old Town font in that package contains an illegal
> glyph name (50_pct_gray) according to this document:
>
> http://partners.adobe.com/public/developer/opentype/index_glyph2.html#4
>
> Still the jvm shouldn't crash on it. A glyph name beginning with
> underscore is valid, but also not handled with the current
> jvm code. Perhaps someone who knows more about fonts could add
> support for underscores. In the meantime, here's a patch for
> java/jdk15/files to avoid the crash.
Trying attachment again, also inline...
========== patch-j2se::font::t1.c ==================
--- ../../j2se/src/share/native/sun/font/t2k/t1.c.orig Tue Oct 19 15:00:39 2004
+++ ../../j2se/src/share/native/sun/font/t2k/t1.c Tue Jul 18 21:42:18 2006
@@ -2035,9 +2035,10 @@
if ( firstChar >= 'A' && firstChar <= 'Z' )
lookupIndex = firstChar - 'A';
- else
+ else if ( firstChar >= 'a' && firstChar <= 'z' )
lookupIndex = firstChar - 'a' + 26;
-
+ else /* underscore is also valid but not handled */
+ return 0;
startIndex = PSNAME_START_INDEX[ lookupIndex ];
endIndex = PSNAME_START_INDEX[ lookupIndex + 1 ];
More information about the freebsd-java
mailing list