Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 19 Jul 2006 12:16:46 -0400
From:      Kurt Miller <lists@intricatesoftware.com>
To:        freebsd-java@freebsd.org
Subject:   Re: diablo 1.5 crash
Message-ID:  <200607191216.46845.lists@intricatesoftware.com>
In-Reply-To: <200607182159.38840.kurt@intricatesoftware.com>
References:  <200607131456.604@centrum.cz> <200607152340.1335@centrum.cz> <200607182159.38840.kurt@intricatesoftware.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--Boundary_(ID_YfMvShG5DeTu0nzdOpwIhQ)
Content-type: text/plain; charset=iso-8859-6
Content-transfer-encoding: 7BIT
Content-disposition: inline

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 ];

--Boundary_(ID_YfMvShG5DeTu0nzdOpwIhQ)--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200607191216.46845.lists>