United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
JDK-4795377 : closing sequencer sometimes crashes the VM

Details
Type:
Bug
Submit Date:
2002-12-18
Status:
Closed
Updated Date:
2003-12-17
Project Name:
JDK
Resolved Date:
2003-08-25
Component:
client-libs
OS:
generic
Sub-Component:
javax.sound
CPU:
generic
Priority:
P2
Resolution:
Fixed
Affected Versions:
1.4.2
Fixed Versions:
1.4.2_04 (04)

Related Reports
Backport:
Relates:
Relates:

Sub Tasks

Description

Name: bs26599			Date: 12/17/2002



Run the WTK/MMAPI midi tck test.
It will crash the VM.
WTK/MMAPI now has a workaround. The sequencer is not closed.

An unexpected exception has been detected in native code outside the VM.
Unexpected Signal : EXCEPTION_ACCESS_VIOLATION occurred at PC=0x6D2AB850
Function=[Unknown.]
Library=D:\jdk14101\jre\bin\jsound.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 com.sun.media.sound.MixerThread.runNative(Native Method)
	at com.sun.media.sound.MixerThread.run(MixerThread.java:314)




======================================================================


###@###.### 2003-03-18:

When I run the following test program on 1.4.2beta, I get crashes - possibly related to this bug:

	<test program moved to bug 4835956>

###@###.### 2003-03-24
	Removed the test program. It did produce a crash, but at Sequencer.open() and not at close(). So I filed a new bug for it: 4835956, which is fixed and integrated for mantis-beta. 

	This bug here - crash at Sequencer.close() - remains not reproducible by me. I may have to install the WTK TCK to find out more.

                                    

Comments
PUBLIC COMMENTS

closing sequencer sometimes crashes the VM
                                     
2004-06-10
EVALUATION


###@###.### 2002-12-17
	Need to find out how to reproduce this bug.


###@###.### 2003-08-23
	A long debug session led to a usable test case. The cause is the Audio Engine's non-thread safety: interactive MIDI events (inserted to a sequencer with MidiChannel's) can under certain conditions still be tried to be played after the sequencer object was closed (and the native object free'd), causing an ellgal access to the free'd memory. The fix consists in cleaning the queue from the sequencer's events (if any) before closing and freeing.
                                     
2004-06-11
CONVERTED DATA

BugTraq+ Release Management Values

COMMIT TO FIX:
1.4.2_04
tiger

FIXED IN:
1.4.2_04
tiger

INTEGRATED IN:
1.4.2_04
tiger
tiger-b17

VERIFIED IN:
1.4.2_04
tiger


                                     
2004-06-14



Hardware and Software, Engineered to Work Together