United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: JDK-6471418 StackOverflowError due to recursion at sun.font.TrueTypeFont.getTableBuffer
JDK-6471418 : StackOverflowError due to recursion at sun.font.TrueTypeFont.getTableBuffer

Details
Type:
Bug
Submit Date:
2006-09-15
Status:
Closed
Updated Date:
2011-03-24
Project Name:
JDK
Resolved Date:
2007-02-08
Component:
client-libs
OS:
windows
Sub-Component:
2d
CPU:
x86
Priority:
P2
Resolution:
Fixed
Affected Versions:
5.0u10
Fixed Versions:
5.0u11 (b01)

Related Reports
Backport:
Backport:

Sub Tasks

Description
This bug is intended for java sustaining team for radiance case 64990026
(attention Vaibhav Kulkarni)

This issue is first observed with Starwood's lightspeed application
with FVB delievered on (7/17) and FVB (7/26)
Here's backgroud regarding the FVBs:

* 7/17 FVB contains fixes to :

- crashes (esc 1-17031590/CR 6259348)
- deadlock (esc 1-18423733/CR 6190373)

>Please find the build with the fix for CR 6190373 at: >http://gaurav.india.sun.com/STARWOODS/17-July-06

* 7/26 FVB:
There is no new bugid for this FVB, just a rework of the previous fix.
>http://gaurav.india.sun.com/STARWOODS/26-July-06/

* 9/13 FVB:
A new FVB was sent to Starwood that address the StackOverflow issue,
but apparently has triggered a new type of crash in IE.

data is in /net/cores.central/cores/dir31/64990026/0725

javaconsole.stackoverflow.txt:

java.lang.ThreadDeath
    at java.lang.Thread.stop(Unknown Source)
    at java.lang.ThreadGroup.stopOrSuspend(Unknown Source)
    at java.lang.ThreadGroup.stop(Unknown Source)
    at sun.awt.AppContext.dispose(Unknown Source)
    at sun.applet.AppletClassLoader.release(Unknown Source)
    at sun.plugin.security.PluginClassLoader.release(Unknown Source)
    at sun.applet.AppletPanel.release(Unknown Source)
    at sun.applet.AppletPanel.sendEvent(Unknown Source)
    at sun.plugin.AppletViewer.onPrivateClose(Unknown Source)
    at sun.plugin.AppletViewer$1.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
java.lang.StackOverflowError
    at java.lang.Exception.<init>(Unknown Source)
    at java.io.IOException.<init>(Unknown Source)
    at java.nio.channels.ClosedChannelException.<init>(Unknown
Source)
    at sun.nio.ch.FileChannelImpl.ensureOpen(Unknown Source)
    at sun.nio.ch.FileChannelImpl.position(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)

    <many more similiar lines deleted>

vmlog.OOM.txt:

&quot;thread applet-com.lightspeed.web.sorttable.SortTableApplet.class&quot; prio=4 tid=0x0e8947d0 nid=0xbf4 runnable [0x10e03000..0x10e5fae8]
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.&lt;init&gt;(Unknown Source)
    at java.lang.Exception.&lt;init&gt;(Unknown Source)
    at java.io.IOException.&lt;init&gt;(Unknown Source)
    at java.nio.channels.ClosedChannelException.&lt;init&gt;(Unknown Source)
    at sun.nio.ch.FileChannelImpl.ensureOpen(Unknown Source)
    at sun.nio.ch.FileChannelImpl.position(Unknown Source)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    - locked &lt;0x2134c5b0&gt; (a sun.font.TrueTypeFont)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    - locked &lt;0x2134c5b0&gt; (a sun.font.TrueTypeFont)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    - locked &lt;0x2134c5b0&gt; (a sun.font.TrueTypeFont)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    - locked &lt;0x2134c5b0&gt; (a sun.font.TrueTypeFont)
    at sun.font.TrueTypeFont.getTableBuffer(Unknown Source)
    - locked &lt;0x2134c5b0&gt; (a sun.font.TrueTypeFont)

    <many more similiar lines deleted>

                                    

Comments
EVALUATION

StackOverFlowError is caused because of the recursive calls made by the getTableBuffer method in TrueTypeFont.java. These recursive calls happen when the application encounters ClosedChannelException. Prior to making the recursive call, the I/O channel is not closed.
                                     
2006-10-11



Hardware and Software, Engineered to Work Together