fix create modulesout only if it doesn't exist

This commit is contained in:
adam-m 2013-02-13 11:20:19 -05:00
parent 6816a1eaf1
commit d583722da5

View File

@ -855,6 +855,7 @@ public class Case {
/**
* Check for existence of certain case sub dirs and create them if needed.
*
* @param openedCase
*/
private static void checkSubFolders(Case openedCase) {
@ -862,15 +863,16 @@ public class Case {
File modulesOutputDirF = new File(modulesOutputDir);
if (!modulesOutputDirF.exists()) {
logger.log(Level.INFO, "Creating modules output dir for the case.");
}
try {
if (! modulesOutputDirF.mkdir() ) {
if (!modulesOutputDirF.mkdir()) {
logger.log(Level.SEVERE, "Error creating modules output dir for the case, dir: " + modulesOutputDir);
}
} catch (SecurityException e) {
logger.log(Level.SEVERE, "Error creating modules output dir for the case, dir: " + modulesOutputDir, e);
}
}
}
//case change helper
private static void doCaseChange(Case toChangeTo) {