Program: 3625
Project: 3625
Buggy source:
/** 
 * Scan a zipfile for file path patterns matching the scan spec. 
 */
private void scanZipFile(final File zipFileFile,final ZipFile zipFile,final LogNode log){
  String prevParentRelativePath=null;
  ScanSpecPathMatch prevParentMatchStatus=null;
  int entryIdx=0;
  for (final Enumeration<? extends ZipEntry> entries=zipFile.entries(); entries.hasMoreElements(); ) {
    if ((entryIdx++ & 0x3ff) == 0) {
      if (interruptionChecker.checkAndReturn()) {
        return;
      }
    }
    final ZipEntry zipEntry=entries.nextElement();
    String relativePath=zipEntry.getName();
    if (relativePath.startsWith("String_Node_Str")) {
      relativePath=relativePath.substring(1);
    }
    final boolean isDir=zipEntry.isDirectory();
    if (isDir) {
      continue;
    }
    final int lastSlashIdx=relativePath.lastIndexOf("String_Node_Str");
    final String parentRelativePath=lastSlashIdx < 0 ? "String_Node_Str" : relativePath.substring(0,lastSlashIdx + 1);
    final boolean parentRelativePathChanged=!parentRelativePath.equals(prevParentRelativePath);
    final ScanSpecPathMatch parentMatchStatus=prevParentRelativePath == null || parentRelativePathChanged ? scanSpec.pathWhitelistMatchStatus(parentRelativePath) : prevParentMatchStatus;
    prevParentRelativePath=parentRelativePath;
    prevParentMatchStatus=parentMatchStatus;
    if (parentMatchStatus != ScanSpecPathMatch.WITHIN_WHITELISTED_PATH && (parentMatchStatus != ScanSpecPathMatch.AT_WHITELISTED_CLASS_PACKAGE || !scanSpec.isSpecificallyWhitelistedClass(relativePath))) {
      continue;
    }
    if (log != null) {
      log.log("String_Node_Str" + relativePath);
    }
    if (ClasspathRelativePath.isClassfile(relativePath)) {
      classfileMatches.add(new ClasspathResourceInZipFile(zipFileFile,relativePath,zipEntry));
    }
    for (    final FilePathTesterAndMatchProcessorWrapper fileMatcher : scanSpec.getFilePathTestersAndMatchProcessorWrappers()) {
      if (fileMatcher.filePathMatches(zipFileFile,relativePath,log)) {
        fileMatches.put(fileMatcher.fileMatchProcessorWrapper,new ClasspathResourceInZipFile(zipFileFile,relativePath,zipEntry));
      }
    }
    if (relativePath.equalsIgnoreCase("String_Node_Str")) {
      fastManifestParser=new FastManifestParser(zipFile,zipEntry,log);
    }
  }
  fileToLastModified.put(zipFileFile,zipFileFile.lastModified());
}

Fixed version (ground truth):
/** 
 * Scan a zipfile for file path patterns matching the scan spec. 
 */
private void scanZipFile(final File zipFileFile,final ZipFile zipFile,final LogNode log){
  String prevParentRelativePath=null;
  ScanSpecPathMatch prevParentMatchStatus=null;
  int entryIdx=0;
  for (final Enumeration<? extends ZipEntry> entries=zipFile.entries(); entries.hasMoreElements(); ) {
    if ((entryIdx++ & 0x3ff) == 0) {
      if (interruptionChecker.checkAndReturn()) {
        return;
      }
    }
    final ZipEntry zipEntry=entries.nextElement();
    String relativePath=zipEntry.getName();
    if (relativePath.startsWith("String_Node_Str")) {
      relativePath=relativePath.substring(1);
    }
    final boolean isDir=zipEntry.isDirectory();
    if (isDir) {
      continue;
    }
    final int lastSlashIdx=relativePath.lastIndexOf("String_Node_Str");
    final String parentRelativePath=lastSlashIdx < 0 ? "String_Node_Str" : relativePath.substring(0,lastSlashIdx + 1);
    final boolean parentRelativePathChanged=!parentRelativePath.equals(prevParentRelativePath);
    final ScanSpecPathMatch parentMatchStatus=prevParentRelativePath == null || parentRelativePathChanged ? scanSpec.pathWhitelistMatchStatus(parentRelativePath) : prevParentMatchStatus;
    prevParentRelativePath=parentRelativePath;
    prevParentMatchStatus=parentMatchStatus;
    if (relativePath.equalsIgnoreCase("String_Node_Str")) {
      if (log != null) {
        log.log("String_Node_Str" + relativePath);
      }
      fastManifestParser=new FastManifestParser(zipFile,zipEntry,log);
    }
    if (parentMatchStatus != ScanSpecPathMatch.WITHIN_WHITELISTED_PATH && (parentMatchStatus != ScanSpecPathMatch.AT_WHITELISTED_CLASS_PACKAGE || !scanSpec.isSpecificallyWhitelistedClass(relativePath))) {
      continue;
    }
    if (log != null) {
      log.log("String_Node_Str" + relativePath);
    }
    if (ClasspathRelativePath.isClassfile(relativePath)) {
      classfileMatches.add(new ClasspathResourceInZipFile(zipFileFile,relativePath,zipEntry));
    }
    for (    final FilePathTesterAndMatchProcessorWrapper fileMatcher : scanSpec.getFilePathTestersAndMatchProcessorWrappers()) {
      if (fileMatcher.filePathMatches(zipFileFile,relativePath,log)) {
        fileMatches.put(fileMatcher.fileMatchProcessorWrapper,new ClasspathResourceInZipFile(zipFileFile,relativePath,zipEntry));
      }
    }
  }
  fileToLastModified.put(zipFileFile,zipFileFile.lastModified());
}