added attribute to ignore a findbugs style error

Former-commit-id: e675e7d62a96807f686f8a3a992b97be13b7e0dd
This commit is contained in:
Jeremy Long
2013-06-03 20:17:07 -04:00
parent 92d306f777
commit d243bf4f48

View File

@@ -111,6 +111,8 @@ public class ReportGenerator {
* *
* @return a Velocity Context. * @return a Velocity Context.
*/ */
@edu.umd.cs.findbugs.annotations.SuppressWarnings(value = "RV_RETURN_VALUE_IGNORED_INFERRED",
justification = "No plan to fix this style issue")
private Context createContext() { private Context createContext() {
final ToolManager manager = new ToolManager(); final ToolManager manager = new ToolManager();
final Context c = manager.createContext(); final Context c = manager.createContext();
@@ -196,7 +198,10 @@ public class ReportGenerator {
try { try {
final File outDir = new File(outFileName).getParentFile(); final File outDir = new File(outFileName).getParentFile();
if (!outDir.exists()) { if (!outDir.exists()) {
outDir.mkdirs(); boolean created = outDir.mkdirs();
if (!created) {
throw new Exception("Unable to create directory '" + outDir.getAbsolutePath() + "'.");
}
} }
outputStream = new FileOutputStream(outFileName); outputStream = new FileOutputStream(outFileName);