United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: 6619480 Modality-related livelock
6619480 : Modality-related livelock

Details
Type:
Bug
Submit Date:
2007-10-20
Status:
Closed
Updated Date:
2010-09-08
Project Name:
JDK
Resolved Date:
2008-06-16
Component:
deploy
OS:
windows
Sub-Component:
plugin
CPU:
generic
Priority:
P3
Resolution:
Fixed
Affected Versions:
6u5
Fixed Versions:
6u10

Related Reports
Relates:
Relates:

Sub Tasks

Description
The simple ModalityTest written for 6605191 is exhibiting livelock at least on IE 7 when we force a reload of the applet while the modal dialog is open. Likely we are leaving a nested message pump running on the browser's main thread due to the premature termination of the applet.

                                    

Comments
SUGGESTED FIX

http://sa.sfbay.sun.com/projects/deployment_data/6u10/6619480.0
testcase: http://j2se.east.sun.com/deployment/www/tests/1.6.0_10/6619480/
                                     
2008-01-07
EVALUATION

There were a few related problems in this bug. The first and most
major was that during the message loop in WindowsHelper.c, the event
object being used might be destroyed during processing of one of the
messages, and if this happened, the previous code would go into an
infinite loop due to an incorrect termination condition. This was
probably the cause of other mysterious problems in this code seen
earlier. Fixed this and simplified the message loop to re-check the
event object after each message dispatched.

The ModalitySupport class needed to re-notify the browser's main
thread after consuming one notification, to properly unwind the stack
if multiple message loops were running on the stack. Similar code
exists in for example AbstractPlugin.doJavaObjectOp().

A couple of additional error checks were also added to the
WindowsEvent and WindowsHelper classes.

The preexisting test case in the workspace was enhanced and brought in
sync with the regression test for this bug.
                                     
2008-01-07



Hardware and Software, Engineered to Work Together