diff -r f8db6d6a6f71 -r b0de5e2762ed jdk/src/share/classes/java/awt/datatransfer/SystemFlavorMap.java --- a/jdk/src/share/classes/java/awt/datatransfer/SystemFlavorMap.java Wed Nov 13 20:16:43 2013 +0400 +++ b/jdk/src/share/classes/java/awt/datatransfer/SystemFlavorMap.java Thu Nov 14 10:52:19 2013 +0400 @@ -40,7 +40,6 @@ import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; -import java.util.Iterator; import java.util.LinkedHashSet; import java.util.List; import java.util.Map; @@ -1321,16 +1320,16 @@ } private List getAllNativesForType(String type) { - List retval = null; + Set retval = null; for (DataFlavor dataFlavor : convertMimeTypeToDataFlavors(type)) { List natives = getFlavorToNative().get(dataFlavor); if (natives != null && !natives.isEmpty()) { if (retval == null) { - retval = new ArrayList<>(); + retval = new LinkedHashSet<>(); } retval.addAll(natives); } } - return retval; + return retval == null ? null : new ArrayList<>(retval); } }