bug fixes

Former-commit-id: 266897e8a32735a77f1b3e7aa1e0842e0fc69b65
This commit is contained in:
Jeremy Long
2012-12-20 21:39:02 -05:00
parent 36ecf7c7fd
commit 23caa1d0b5
4 changed files with 11 additions and 2 deletions

View File

@@ -482,6 +482,12 @@ public class JarAnalyzer extends AbstractAnalyzer {
protected void parseManifest(Dependency dependency) throws IOException {
JarFile jar = new JarFile(dependency.getActualFilePath());
Manifest manifest = jar.getManifest();
if (manifest == null) {
Logger.getLogger(JarAnalyzer.class.getName()).log(Level.SEVERE,
"Jar file '{0}' does not contain a manifest.",
dependency.getFileName());
return;
}
Attributes atts = manifest.getMainAttributes();
EvidenceCollection vendorEvidence = dependency.getVendorEvidence();