Details
-
Bug
-
Status: Resolved
-
Resolution: Won't Fix
-
1.5
-
None
-
None
-
Operating System: All
Platform: PC
Description
I have two svg files to demonstrate the issue. When I try to open the first
file, Batik hangs during rendering process, and second file crashes VM.
Both happens when I use the stroke-dasharray property in style attribute. If I
remove this property, both files are opening fine. In these files, the
coordinates used are very high. When i tried the same shapes with smaller
coordinates, files opened fine.
following are the 2 svgs.
File: Test1
-------------------------------------------------------------------------------
<?xml version='1.0' encoding='ISO-8859-1' ?>
<svg id="svgAll" width="900" xmlns="http://www.w3.org/2000/svg" height="600"
viewBox="0 0 9000000000 6000000000"
xmlns:cs="http://www.savagesoftware.com/dgn2svg" xml:space="preserve"
xmlns:xlink="http://www.w3.org/1999/xlink" text-rendering="optimizeSpeed" image-
rendering="optimizeSpeed" shape-rendering="optimizeSpeed"
preserveAspectRatio="xMidYMid">
<style type="text/css">
<![CDATA[
.line
]]>
</style>
<rect x="0" y="0" fill="#000000" width="9000000000" height="6000000000"/>
<defs/>
<g>
<line x1="100000000" y1="200000000" x2="4000000000" y2="3000000000"
class="line" />
<path d="M300000000 400000000 5000000000 6000000000" class="line" />
<path d="M300000000,300000000 A1000000000 1000000000 0 0 0 1500000000
1500000000" class="line" />
</g>
</svg>
-------------------------------------------------------------------------------
File: Test2
-------------------------------------------------------------------------------
<?xml version='1.0' encoding='ISO-8859-1' ?>
<!-- Generator: Savage Dgn2Svg Converter -->
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG
20010904//EN" "http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd" [
<!ENTITY st31 "stroke:#FF0000;stroke-width:142.64906666666667;stroke-
dasharray:151.564633,267.467000">
]>
<svg id="svgAll" width="900" xmlns="http://www.w3.org/2000/svg" height="600"
viewBox="-1305267092.3 89202697.65 508486.13867 294213.7"
xmlns:cs="http://www.savagesoftware.com/dgn2svg" xml:space="preserve"
xmlns:xlink="http://www.w3.org/1999/xlink" text-rendering="optimizeSpeed" image-
rendering="optimizeSpeed" shape-rendering="optimizeSpeed"
preserveAspectRatio="xMidYMid">
<rect x="-1305267092.3" y="89202697.65" fill="#000000" width="508486.13867"
height="294213.7"/>
<defs/>
<g>
<g id="ELA2_8" class="Layer-1-55">
<path d="M-1304851927.4 89427116.57 A1940.7473267 698.6260632 0 0 0 -
1304855793.6 89426789.689" style="&st31;"/>
</g>
</g>
</svg>
-------------------------------------------------------------------------------
When VM crashed, I got a log file, which shows a stack overflow outside VM,
during StrokeShapePainter.getPaintedArea() procedure call. Below is the full
error dump..
File: error dump
------------------------------------------------------------------------------
An unrecoverable stack overflow has occurred.
An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_STACK_OVERFLOW occurred at PC=0x6D137F36
Function=[Unknown.]
Library=C:\Program Files\Java\j2re1.4.1_01\bin\dcpr.dll
NOTE: We are unable to locate the function name symbol for the error
just occurred. Please refer to release documentation for possible
reason and solutions.
Current Java thread:
at sun.dc.pr.PathDasher.appendCubic(Native Method)
at java.awt.BasicStroke.createStrokedShape(BasicStroke.java:337)
at org.apache.batik.gvt.StrokeShapePainter.getPaintedArea(Unknown
Source)
at org.apache.batik.gvt.StrokeShapePainter.getPaintedBounds2D(Unknown
Source)
at org.apache.batik.gvt.CompositeShapePainter.getPaintedBounds2D
(Unknown Source)
at org.apache.batik.gvt.ShapeNode.getPrimitiveBounds(Unknown Source)
at
org.apache.batik.gvt.AbstractGraphicsNode.getTransformedPrimitiveBounds(Unknown
Source)
at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds
(Unknown Source)
at
org.apache.batik.gvt.CompositeGraphicsNode.getTransformedPrimitiveBounds
(Unknown Source)
at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds
(Unknown Source)
at
org.apache.batik.gvt.CompositeGraphicsNode.getTransformedPrimitiveBounds
(Unknown Source)
at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds
(Unknown Source)
at
org.apache.batik.gvt.CompositeGraphicsNode.getTransformedPrimitiveBounds
(Unknown Source)
at org.apache.batik.gvt.AbstractGraphicsNode.getTransformedBounds
(Unknown Source)
at org.apache.batik.gvt.CompositeGraphicsNode.getPrimitiveBounds
(Unknown Source)
at org.apache.batik.gvt.filter.GraphicsNodeRable8Bit.getBounds2D
(Unknown Source)
at org.apache.batik.gvt.filter.GraphicsNodeRable8Bit.createRendering
(Unknown Source)
at org.apache.batik.gvt.renderer.StaticRenderer.renderGNR(Unknown
Source)
at org.apache.batik.gvt.renderer.StaticRenderer.updateWorkingBuffers
(Unknown Source)
at org.apache.batik.gvt.renderer.StaticRenderer.repaint(Unknown Source)
at org.apache.batik.gvt.renderer.StaticRenderer.repaint(Unknown Source)
at org.apache.batik.swing.gvt.GVTTreeRenderer.run(Unknown Source)
Dynamic libraries:
0x00400000 - 0x00406000 C:\Program Files\Java\j2re1.4.1_01\bin\javaw.exe
0x77F80000 - 0x77FFD000 C:\WINNT\system32\ntdll.dll
0x7C2D0000 - 0x7C332000 C:\WINNT\system32\ADVAPI32.dll
0x7C570000 - 0x7C623000 C:\WINNT\system32\KERNEL32.DLL
0x77D30000 - 0x77DA1000 C:\WINNT\system32\RPCRT4.DLL
0x77E10000 - 0x77E75000 C:\WINNT\system32\USER32.dll
0x77F40000 - 0x77F7B000 C:\WINNT\system32\GDI32.DLL
0x78000000 - 0x78045000 C:\WINNT\system32\MSVCRT.dll
0x6D330000 - 0x6D45A000 C:\Program Files\Java\j2re1.4.1_01
\bin\client\jvm.dll
0x77570000 - 0x775A0000 C:\WINNT\system32\WINMM.dll
0x6D1D0000 - 0x6D1D7000 C:\Program Files\Java\j2re1.4.1_01\bin\hpi.dll
0x6D300000 - 0x6D30D000 C:\Program Files\Java\j2re1.4.1_01
\bin\verify.dll
0x6D210000 - 0x6D229000 C:\Program Files\Java\j2re1.4.1_01\bin\java.dll
0x6D320000 - 0x6D32D000 C:\Program Files\Java\j2re1.4.1_01\bin\zip.dll
0x6D000000 - 0x6D0FB000 C:\Program Files\Java\j2re1.4.1_01\bin\awt.dll
0x77800000 - 0x7781E000 C:\WINNT\system32\WINSPOOL.DRV
0x76620000 - 0x76630000 C:\WINNT\system32\MPR.DLL
0x75E60000 - 0x75E7A000 C:\WINNT\system32\IMM32.dll
0x77A50000 - 0x77B3F000 C:\WINNT\system32\ole32.dll
0x6D180000 - 0x6D1D0000 C:\Program Files\Java\j2re1.4.1_01
\bin\fontmanager.dll
0x72800000 - 0x72846000 C:\WINNT\system32\ddraw.dll
0x728A0000 - 0x728A6000 C:\WINNT\system32\DCIMAN32.dll
0x72D90000 - 0x72E03000 C:\WINNT\system32\D3DIM.DLL
0x1B7C0000 - 0x1B7CB000 C:\Program Files\Lotus\Sametime
Client\ACTIVMON.dll
0x6D2D0000 - 0x6D2DE000 C:\Program Files\Java\j2re1.4.1_01\bin\net.dll
0x75050000 - 0x75058000 C:\WINNT\system32\WSOCK32.dll
0x75030000 - 0x75044000 C:\WINNT\system32\WS2_32.DLL
0x75020000 - 0x75028000 C:\WINNT\system32\WS2HELP.DLL
0x6D2E0000 - 0x6D2E8000 C:\Program Files\Java\j2re1.4.1_01\bin\nio.dll
0x1BD00000 - 0x1BD09000 C:\PROGRA~1\MYWEBS~1\bar\1.bin\mwsoeplg.dll
0x782F0000 - 0x78535000 C:\WINNT\system32\SHELL32.dll
0x70A70000 - 0x70AD9000 C:\WINNT\system32\SHLWAPI.dll
0x71710000 - 0x71794000 C:\WINNT\system32\COMCTL32.dll
0x779B0000 - 0x77A4B000 C:\WINNT\system32\OLEAUT32.dll
0x77820000 - 0x77827000 C:\WINNT\system32\VERSION.dll
0x759B0000 - 0x759B6000 C:\WINNT\system32\LZ32.DLL
0x6D130000 - 0x6D152000 C:\Program Files\Java\j2re1.4.1_01\bin\dcpr.dll
0x77920000 - 0x77943000 C:\WINNT\system32\imagehlp.dll
0x72A00000 - 0x72A2D000 C:\WINNT\system32\DBGHELP.dll
0x690A0000 - 0x690AB000 C:\WINNT\system32\PSAPI.DLL
Local Time = Tue Oct 19 17:59:50 2004
Elapsed Time = 7
#
- The exception above was detected in native code outside the VM
# - Java VM: Java HotSpot(TM) Client VM (1.4.1_01-b01 mixed mode)
# - An error report file has been saved as hs_err_pid1968.log.
- Please refer to the file for further information.
#
-------------------------------------------------------------------------------