made error handling more robust so analysis should stop when something goes wrong with a signle jar

Former-commit-id: f873948c981239f37fb0083b34906be31c0e9ca1
This commit is contained in:
Jeremy Long
2013-12-21 07:46:47 -05:00
parent 611635a9a2
commit f1e0b7a94f

View File

@@ -336,6 +336,12 @@ public class Engine {
a.analyze(d, this);
} catch (AnalysisException ex) {
d.addAnalysisException(ex);
} catch (Throwable ex) {
final String axMsg = String.format("An unexpected error occured during analysis of '%s'", d.getActualFilePath());
AnalysisException ax = new AnalysisException(axMsg, ex);
d.addAnalysisException(ax);
Logger.getLogger(Engine.class.getName()).log(Level.SEVERE, axMsg);
Logger.getLogger(Engine.class.getName()).log(Level.FINE, axMsg, ex);
}
}
}