FULL PRODUCT VERSION :
java version "1.8.0_91"
Java(TM) SE Runtime Environment (build 1.8.0_91-b14)
Java HotSpot(TM) 64-Bit Server VM (build 25.91-b14, mixed mode)
ADDITIONAL OS VERSION INFORMATION :
Darwin MacPro-Robin.local 15.5.0 Darwin Kernel Version 15.5.0: Tue Apr 19 18:36:36 PDT 2016; root:xnu-3248.50.21~8/RELEASE_X86_64 x86_64
A DESCRIPTION OF THE PROBLEM :
The backport of issue JDK-8136763 introduced a new bug.
When you copy-paste, or drag-and-drop 2 files, the data in the transferable for data flavor "text/uri-list" concats the strings.
For example, if you drag-and-drop files:
the transferable wil contain
The problem is located in the CDataTransferer#translateBytes method, which is missing an sb.append(separator); call
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
Follow the steps of the manual testcase available in the OpenJDK (test/java/awt/datatransfer/DataFlavor/MacOsXFileAndMultipleFileCopingTest/MacOsXFileAndMultipleFileCopingTest.java).
This test case fails on jdk8, but succeeds on jdk9
EXPECTED VERSUS ACTUAL BEHAVIOR :
The test case succeeds
The paths of the first two files are grouped into one string, making it impossible to retrieve the 2 separate paths
This bug can be reproduced always.