Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-7148289

[macosx] Deadlock in sun.lwawt.macosx.CWrapper$NSScreen.visibleFrame

    XMLWordPrintable

Details

    • b40
    • x86
    • os_x
    • Verified

    Backports

      Description

        When user starts dragging a window component in NetBeans the AWT thread stays blocked with this stacktrace:

        "AWT-EventQueue-0" prio=5 tid=0x00007fa204b09000 nid=0x16794b000 runnable [0x0000000167948000]
           java.lang.Thread.State: RUNNABLE
        at sun.lwawt.macosx.CWrapper$NSScreen.visibleFrame(Native Method)
        at sun.lwawt.macosx.LWCToolkit.getScreenInsets(LWCToolkit.java:355)
        at java.awt.Window.init(Window.java:497)
        at java.awt.Window.<init>(Window.java:535)
        at java.awt.Frame.<init>(Frame.java:420)
        at java.awt.Frame.<init>(Frame.java:385)
        at javax.swing.SwingUtilities$SharedOwnerFrame.<init>(SwingUtilities.java:1756)
        at javax.swing.SwingUtilities.getSharedOwnerFrame(SwingUtilities.java:1831)
        at javax.swing.JWindow.<init>(JWindow.java:185)
        at javax.swing.JWindow.<init>(JWindow.java:137)
        at org.netbeans.core.windows.view.dnd.DragWindow.<init>(DragWindow.java:85)
        at org.netbeans.core.windows.view.dnd.DragAndDropFeedbackVisualizer.createDragWindow(DragAndDropFeedbackVisualizer.java:101)
        at org.netbeans.core.windows.view.dnd.DragAndDropFeedbackVisualizer.start(DragAndDropFeedbackVisualizer.java:132)
        at org.netbeans.core.windows.view.dnd.TopComponentDragSupport.doStartDrag(TopComponentDragSupport.java:428)
        at org.netbeans.core.windows.view.dnd.TopComponentDragSupport.eventDispatched(TopComponentDragSupport.java:353)
        at java.awt.Toolkit$SelectiveAWTEventListener.eventDispatched(Toolkit.java:2430)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit$ToolkitEventMulticaster.eventDispatched(Toolkit.java:2321)
        at java.awt.Toolkit.notifyAWTEventListeners(Toolkit.java:2280)
        at java.awt.Component.dispatchEventImpl(Component.java:4757)
        at java.awt.Container.dispatchEventImpl(Container.java:2287)
        at java.awt.Component.dispatchEvent(Component.java:4687)
        at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4832)
        at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4509)
        at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4422)
        at java.awt.Container.dispatchEventImpl(Container.java:2273)
        at java.awt.Window.dispatchEventImpl(Window.java:2713)
        at java.awt.Component.dispatchEvent(Component.java:4687)
        at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:703)
        at java.awt.EventQueue.access$000(EventQueue.java:102)
        at java.awt.EventQueue$3.run(EventQueue.java:662)
        at java.awt.EventQueue$3.run(EventQueue.java:660)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:87)
        at java.awt.EventQueue$4.run(EventQueue.java:676)
        at java.awt.EventQueue$4.run(EventQueue.java:674)
        at java.security.AccessController.doPrivileged(Native Method)
        at java.security.ProtectionDomain$1.doIntersectionPrivilege(ProtectionDomain.java:76)
        at java.awt.EventQueue.dispatchEvent(EventQueue.java:673)
        at org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:162)
        at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:244)
        at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:163)
        at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:147)
        at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:139)
        at java.awt.EventDispatchThread.run(EventDispatchThread.java:97)

        Related NetBeans issue:
        https://www.netbeans.org/bugzilla/show_bug.cgi?id=208513

        Please evaluate under what conditions method Wrapper$NSScreen.visibleFrame() can block and if this should be fixed on Java side.

        Thanks!

        Attachments

          Issue Links

            Activity

              People

                kizune Alexander Zuev
                anebuzel Antonín Nebuželský
                Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                  Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: