Fork me on GitHub

CPD Results

The following document contains the results of PMD's CPD 5.0.5.

Duplications

File Line
org\owasp\dependencycheck\analyzer\ArchiveAnalyzer.java 165
org\owasp\dependencycheck\analyzer\JarAnalyzer.java 1036
    @Override
    public void initializeFileTypeAnalyzer() throws Exception {
        final File baseDir = Settings.getTempDirectory();
        tempFileLocation = File.createTempFile("check", "tmp", baseDir);
        if (!tempFileLocation.delete()) {
            final String msg = String.format("Unable to delete temporary file '%s'.", tempFileLocation.getAbsolutePath());
            throw new AnalysisException(msg);
        }
        if (!tempFileLocation.mkdirs()) {
            final String msg = String.format("Unable to create directory '%s'.", tempFileLocation.getAbsolutePath());
            throw new AnalysisException(msg);
        }
    }

    /**
     * The close method deletes any temporary files and directories created during analysis.
     *
     * @throws Exception thrown if there is an exception deleting temporary files
     */
    @Override
    public void close() throws Exception {