JDK-4313374 : JCK-runtime-13rc1 drag and drop test hangs the terminal
  • Type: Bug
  • Component: client-libs
  • Sub-Component: java.awt
  • Affected Version: 1.2.0,1.3.0,1.4.0
  • Priority: P1
  • Status: Closed
  • Resolution: Duplicate
  • OS: solaris_2.6,solaris_7,solaris_8
  • CPU: x86,sparc
  • Submitted: 2000-02-17
  • Updated: 2000-12-15
  • Resolved: 2000-12-15
Related Reports
Duplicate :  
Duplicate :  
Duplicate :  
Duplicate :  
Description
JCK-interactive test failure on Solaris 5.7, 8 (x86/openwin) for JDK_1.3.b01.

Name of the failing test: JCK-runtime-13rc1/tests/api/java_awt/interactive/DnDTests.html#DnDTests jck_exec
ute_positive DnDTests_DnDTests. This Drag and Drop test failed on both Solaris 5.7 and Solaris 8 on x86 platform (Openwin). The screen doesn't respond to the cursor.

Description of the failure:
I used the following script to run the test.

bkante@jtg-i113$ /usr/java1.3/bin/java -fullversion
java full version "katleman.2000.02.08.15.58"

bkante@jtg-i113$ DnDTests_DnDTests.ksh

#!/bin/ksh

PATH=/usr/java1.3/bin:/bin
DISPLAY=jtg-i113:0.0
CLASSPATH=/export/home/jtg-test/tonga_1.3.b01/hotspot/jtg-i113/JCK-runtime-13rc1
et/ultraowl.eng/export/ultraowl1/javatb/testbase/src/JCK-runtime-13rc1/classes:/
K-runtime-13rc1/javatest.jar
LD_LIBRARY_PATH=/net/ultraowl.eng/export/ultraowl1/javatb/testbase/src/JCK-runti

while [ $# -gt 0 ];
do
  if [ $1 = "-jdk" ]; then
    shift 1
    PATH=${1}/bin:${PATH}
    shift 1
  else
    if [ $1 = "-d" ]; then
      shift 1
      if [ $# -gt 0  ]; then
        DISPLAY=$1
        shift 1
      else
        DISPLAY=:0.0
      fi
    fi
  fi
done

export PATH
export DISPLAY
export CLASSPATH
export LD_LIBRARY_PATH
/usr/java1.3/bin/java -hotspot -Djava.security.policy=/net/ultraowl.eng/export/ultraowl1/javatb/testbase/src/JCK-runtime-13rc1/lib/jck.p
olicy -Xfuture  javasoft.sqe.tests.api.java.awt.interactive.DnDTests  -TestCaseID ALL

Run the test and drag and drop the components for atleast 15 times. The cursor will stop working and the screen also doesn't respond to any action. This failure occures during the second test case.

bhoopal.kante@eng 2000-02-16

Updated script:
================

x86-chunnu:[61]% cat DnDTests.ksh
#!/bin/ksh

SWITCH=${1}
PATH=/usr/java1.2/bin:/bin
DISPLAY=`uname -n`:0.0

TESTBASE=/net/ultraowl.eng/export/ultraowl1/javatb/testbase
JCK=${TESTBASE}/src/JCK-runtime-13fcs
CLASSPATH=.:${JCK}/classes:${JCK}/javatest.jar
PATH=/usr/java1.2/bin:/bin

export DISPLAY CLASSPATH PATH

echo
java ${SWITCH} -version
echo
java ${SWITCH} -Djava.security.policy=${JCK}/lib/jck.policy -verify javasoft.sqe.tests.api.java.awt.interactive.DnDTests  -TestCaseID DnDTest0002

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

Observation from Openwin:

This problem is still there in current b21 release. Repeatedly dragging components from left panel and dropping into the right panel will freeze up the mouse cursor and the entire openwin session is hung up. 

Observation from CDE:

The process aborts with "native code exception" rather than just a frozen X session. Please see 
bugID 4349615 for more detail.

vincent.lee@eng 2000-06-29

I have attached a stand-alone test case.
david.mendenhall@eng 2000-07-27

Comments
EVALUATION Commit to fix in Kestrel-Solaris (JCK failure). eric.hawkes@eng 2000-03-26 Please provide an update script for running the test on Merlin. roger.brinkley@Eng 2000-06-26 Tested with the AWT workspace as of 12Dec2000. I am seeing two outstanding problems with the attached test case. 1. If you drag from the Button or Label using the middle mouse button and release over the drop target area you get the following exception: java.awt.dnd.InvalidDnDOperationException: invalid rejectDrop() at sun.awt.dnd.SunDropTargetContextPeer.rejectDrop(SunDropTargetContextPeer.java:629) at java.awt.dnd.DropTargetContext.rejectDrop(DropTargetContext.java:191) at java.awt.dnd.DropTargetDropEvent.rejectDrop(DropTargetDropEvent.java:198) at DnDTests$Panel2$dropP.drop(DnDTests.java:393) at java.awt.dnd.DropTarget.drop(DropTarget.java:395) at sun.awt.dnd.SunDropTargetContextPeer.processDropMessage(SunDropTargetContextPeer.java:564) at sun.awt.dnd.SunDropTargetContextPeer.access$800(SunDropTargetContextPeer.java:55) at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchDropEvent(SunDropTargetContextPeer.java:827) at sun.awt.dnd.SunDropTargetContextPeer$EventDispatcher.dispatchEvent(SunDropTargetContextPeer.java:745) at sun.awt.dnd.SunDropTargetEvent.dispatch(SunDropTargetEvent.java:30) at java.awt.Component.dispatchEventImpl(Component.java:2784) at java.awt.Container.dispatchEventImpl(Container.java:1361) at java.awt.Component.dispatchEvent(Component.java:2766) at java.awt.EventQueue.dispatchEvent(EventQueue.java:437) at java.awt.EventDispatchThread.pumpOneEvent(EventDispatchThread.java:140) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:126) at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:121) at java.awt.EventDispatchThread.run(EventDispatchThread.java:99) I am not sure if this is desirable behavior. This exception does not appear when dragging with the left mouse button. 2. With fast, repeated dragging, Java will crash. The native stack trace is the same as the one documented in BugID 4379151. david.mendenhall@east 2000-12-12 I believe the exception listed under (1) above is a bug in the test case. dropP.drop(DropTargetDropEvent) calls acceptDrop(int) as its first line of code. However, in failure cases, it subsequently calls rejectDrop(). The API does not permit a DropTargetListener to both accept and reject a drop. If you replace the calls to rejectDrop() with dropComplete(false), the exception disappears. Since (2) is documented more precisely in 4379151, I am closing this bug as a duplicate. david.mendenhall@east 2000-12-14
14-12-2000