JDK-4152184 : Motif peers should never call user code on the AWT-Motif thread
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 1.2.0
  • Priority: P3
  • Status: Closed
  • Resolution: Fixed
  • OS: solaris_2.5
  • CPU: generic
  • Submitted: 1998-06-25
  • Updated: 1999-01-15
  • Resolved: 1999-01-15
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
1.2.0 1.2fcsFixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Description
In the following instances, it's possible for user code to be called by the
AWT-Motif thread, which runs the native message pump.  Errant user code
could then lock up the entire AWT toolkit for the whole Java VM.

	MButtonPeer.action calls Button.getActionCommand
	MCheckboxMenuItemPeer.action calls CheckboxMenuItem.setState
	MCheckboxMenuItemPeer.action calls CheckboxMenuItem.getLabel
	MCheckboxPeer.action calls Checkbox.getCheckboxGroup
	MCheckboxPeer.action calls CheckboxGroup.getSelectedCheckbox
	MCheckboxPeer.action calls Checkbox.getState
	MCheckboxPeer.action calls Checkbox.setState
	MCheckboxPeer.action calls Checkbox.getLabel
	MChoicePeer.action calls Choice.select
	MChoicePeer.action calls Choice.getItem
	MFileDialogPeer.handleSelected calls FileDialog.setFile
	MFileDialogPeer.handleSelected calls FileDialog.setDirectory
	MFileDialogPeer.handleCancel calls FileDialog.setFile
	MListPeer.action calls List.select
	MListPeer.action calls List.getItem
	MListPeer.handleListChanged calls List.getSelectedIndexes
	MMenuItemPeer.action calls MenuItem.getActionCommand
	MPanelPeer.makeCursorsVisible calls Container.getComponentCount
	MPanelPeer.makeCursorsVisible calls Container.getComponent
	MScrollPanePeer.scrolledVertical calls ScrollPane.getVAdjustable
	MScrollPanePeer.scrolledHorizonatal calls ScrollPane.getHAdjustable
	MScrollbarPeer.lineUp calls Scrollbar.setValue
	MScrollbarPeer.lineDown calls Scrollbar.setValue
	MScrollbarPeer.pageUp calls Scrollbar.setValue
	MScrollbarPeer.pageDown calls Scrollbar.setValue
	MScrollbarPeer.dragAbsolute calls Scrollbar.setValue
	MTextAreaPeer.pasteFromClipboard calls Component.getToolkit
	MTextFieldPeer.action calls TextField.getText
	MTextFieldPeer.pasteFromClipboard calls Component.getToolkit
	MTinyChoicePeer.handleWindowEvent calls Choice.getSelectedIndex
	MTinyChoicePeer.handleMouseDown calls Choice.isEnabled
	MTinyChoicePeer.handleMouseDown calls Choice.size
	MTinyChoicePeer.handleMouseDown calls Choice.countItems
	MTinyChoicePeer.handleMouseDown calls Choice.getItem
	MTinyChoicePeer.handleMouseDown calls Choice.getParent
	MTinyChoicePeer.handleMouseDown calls Choice.getSelectedIndex
	MTinyChoicePeer.handleMouseUp calls Choice.isEnabled
	MTinyChoicePeer.handleMouseUp calls Choice.select
	MTinyChoicePeer.handleMouseUp calls Choice.getSelectedItem
	MTinyChoicePeer.handleMouseDrag calls Choice.isEnabled

I doubt this list is 100% complete, but these cases will
cause major problems when multiple AppContexts are in use.

Comments
CONVERTED DATA BugTraq+ Release Management Values COMMIT TO FIX: generic FIXED IN: 1.2fcs INTEGRATED IN: 1.2fcs
17-09-2004

EVALUATION I've managed to pawn this one off on Jeff. I've provided plenty of support code in sun.awt.SunToolkit.java though, so it shouldn't be too bad... fred.ecks@Eng 1998-07-30 jeff.dunn@Eng 1998-09-01 NOT TOO BAD??!! IT *SUCKED*! :-) But, it was necessary. Thanks for driving this one, Fred.
30-07-1998