resolved issue #213

Former-commit-id: e50ac440ea63132f387c28fc2f8e0f3ff81d9896
This commit is contained in:
Jeremy Long
2015-04-14 07:03:07 -04:00
parent 5a329b4a6d
commit 7fb5d5bde5
2 changed files with 5 additions and 1 deletions

View File

@@ -160,6 +160,10 @@ public class CPEAnalyzer implements Analyzer {
}
}
public boolean isOpen() {
return cpe != null && cpe.isOpen();
}
/**
* Searches the data store of CPE entries, trying to identify the CPE for the given dependency based on the evidence contained
* within. The dependency passed in is updated with any identified CPE values.

View File

@@ -118,7 +118,7 @@ public class Engine extends org.owasp.dependencycheck.Engine {
protected Analyzer initializeAnalyzer(Analyzer analyzer) {
if ((analyzer instanceof CPEAnalyzer)) {
CPEAnalyzer cpe = getPreviouslyLoadedCPEAnalyzer();
if (cpe != null) {
if (cpe != null && cpe.isOpen()) {
return cpe;
}
cpe = (CPEAnalyzer) super.initializeAnalyzer(analyzer);