mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-23 20:44:41 +02:00
6894504: javax/swing/JFileChooser/6741890/bug6741890.java fails w/ RuntimeException
Reviewed-by: malenkov
This commit is contained in:
parent
5b04b875ea
commit
ce0d94ffec
1 changed files with 7 additions and 0 deletions
|
@ -29,6 +29,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
import sun.awt.shell.ShellFolder;
|
import sun.awt.shell.ShellFolder;
|
||||||
|
import sun.awt.OSInfo;
|
||||||
|
|
||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.lang.reflect.Field;
|
import java.lang.reflect.Field;
|
||||||
|
@ -43,6 +44,12 @@ public class bug6741890 {
|
||||||
private static final int COUNT = 100000;
|
private static final int COUNT = 100000;
|
||||||
|
|
||||||
public static void main(String[] args) throws Exception {
|
public static void main(String[] args) throws Exception {
|
||||||
|
if (OSInfo.getOSType() != OSInfo.OSType.WINDOWS) {
|
||||||
|
System.out.println("The test is applicable only for Windows. Skipped.");
|
||||||
|
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
String tmpDir = System.getProperty("java.io.tmpdir");
|
String tmpDir = System.getProperty("java.io.tmpdir");
|
||||||
|
|
||||||
if (tmpDir.length() == 0) { //'java.io.tmpdir' isn't guaranteed to be defined
|
if (tmpDir.length() == 0) { //'java.io.tmpdir' isn't guaranteed to be defined
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue