JDK-6382189 : REGRESSION:JPEGMultithread.java is passing with 1.5.0_06-b05 but failing with 1.5.0_07-b01
  • Type: Bug
  • Component: client-libs
  • Sub-Component: 2d
  • Affected Version: 5.0u7
  • Priority: P2
  • Status: Closed
  • Resolution: Duplicate
  • OS: generic
  • CPU: generic
  • Submitted: 2006-02-07
  • Updated: 2010-04-02
  • Resolved: 2006-02-07
Related Reports
Duplicate :  
Relates :  
Relates :  
Description
Testcase from regression workspace, JPEGMultithread.java is passing with 1.5.0_06-b05 and failing with 1.5.0_07-b01 on all platforms.

Testcase Location:
==================
/net/urts071.india/export6/testSuites/Regression/workspace_150/test/com/sun/image/codec/jpeg/JPEGMultithread.java

JDK:
====
java version "1.5.0_07-ea"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_07-ea-b01)
Java HotSpot(TM) Client VM (build 1.5.0_07-ea-b01, mixed mode, sharing)

Steps to reproduce:
===================
1. Install JDK in test machine.
2. copy attached JPEGMultithread.java file into test machine.
3. Compile .java files with tested JDK with following command:
   <jdk location>/bin/javac JPEGMultithread.java
4. Start the test with the following command:
   <jdk location>java JPEGMultithread

Output for 1.5.0_07-b01:
=====================
Spawning new thread
Reader 0 done
Spawning new thread
Reader 1 done
Exception in thread "WriterThread0" com.sun.image.codec.jpeg.ImageFormatException: JPEG lib error
        at sun.awt.image.codec.JPEGImageEncoderImpl.writeJPEGStream(Native Method)
        at sun.awt.image.codec.JPEGImageEncoderImpl.encode(JPEGImageEncoderImpl.java:472)
        at sun.awt.image.codec.JPEGImageEncoderImpl.encode(JPEGImageEncoderImpl.java:228)
        at sun.awt.image.codec.JPEGImageEncoderImpl.encode(JPEGImageEncoderImpl.java:235)
        at WriterThread.run(JPEGMultithread.java:88)
        at java.lang.Thread.run(Thread.java:595)


Output for 1.5.0_06-b05:
=====================

Spawning new thread
Reader 0 done
Spawning new thread
Reader 1 done
Writer 0 done

Comments
EVALUATION Looks very similar to the 6317365 that was fixed in 6.0b53. There was the change in order of delivering of the exceptions thrown in native code due to the fix of hotspot bug 6253381. Please note that fix of the hotspot bug have been backported to the 5.0u7 b01.
07-02-2006