Changeset 4821


Ignore:
Timestamp:
02/19/09 12:28:05 (11 years ago)
Author:
melissa
Message:

Make sure temporary file name prefix is at least 3 characters long.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/components/test-suite/src/loci/tests/testng/FormatWriterTest.java

    r4820 r4821  
    120120      String prefix = id.substring(id.lastIndexOf(File.separator) + 1, 
    121121        id.lastIndexOf(".")); 
     122      // prefix must be at least 3 chars, or File.createTempFile(String, String) 
     123      // will throw an exception 
     124      while (prefix.length() < 3) prefix = "x" + prefix; 
    122125      String suffix = "." + writer.getSuffixes()[0]; 
    123126      File tmpFile = File.createTempFile(prefix, suffix); 
Note: See TracChangeset for help on using the changeset viewer.