Program: 109547
Project: 109547
Buggy source:
/** 
 * Decompiles .class files and nested archives in the given archive, as allowed by the given filter. <p> Nested archives will be decompiled into directories matching the name of the archive, e.g. <code>foo.ear/bar.jar/src/com/foo/bar/Baz.java</code>. <p> Required directories will be created as needed.
 * @param archive The archive containing source files and archives.
 * @param outputDir The directory where decompiled .java files will be placed.
 * @param filter Decides which classes will be decompiled.
 * @returns Result with all decompilation failures. Never throws.
 */
public DecompilationResult decompileArchive(File archive,File outputDir,Filter<ZipEntry> filter) throws DecompilationException {
  Checks.checkFileToBeRead(archive,"String_Node_Str");
  Checks.checkDirectoryToBeFilled(outputDir,"String_Node_Str");
  log.info("String_Node_Str" + archive.getAbsolutePath() + "String_Node_Str"+ outputDir.getAbsolutePath()+ "String_Node_Str");
  JarFile jar=loadJar(archive);
  DecompilerSettings settings=getDefaultSettings(outputDir);
  settings.setTypeLoader(new CompositeTypeLoader(new JarTypeLoader(jar),settings.getTypeLoader()));
  MetadataSystem metadataSystem=new NoRetryMetadataSystem(settings.getTypeLoader());
  int classesDecompiled=0;
  DecompilationResult res=new DecompilationResult();
  Filter.Result filterRes=Filter.Result.ACCEPT;
  final Enumeration<JarEntry> entries=jar.entries();
  while (entries.hasMoreElements()) {
    final JarEntry entry=entries.nextElement();
    if (filter != null)     filterRes=filter.decide(entry);
    if (filterRes == Filter.Result.REJECT)     continue;
    if (filterRes == Filter.Result.STOP)     break;
    final String name=entry.getName();
    if (!name.endsWith("String_Node_Str"))     continue;
    final String typeName=StringUtils.removeEnd(name,"String_Node_Str");
    try {
      File outputFile=this.decompileType(metadataSystem,typeName);
      if (outputFile != null)       res.addDecompiled(name,outputFile.getAbsolutePath());
      if (++classesDecompiled % 100 == 0)       metadataSystem=new NoRetryMetadataSystem(settings.getTypeLoader());
    }
 catch (    Throwable th) {
      String msg="String_Node_Str" + archive.getPath() + "String_Node_Str"+ name+ "String_Node_Str"+ th.getMessage();
      DecompilationFailure ex=new DecompilationFailure(msg,name,th);
      log.log(Level.SEVERE,msg,ex);
      res.addFailure(ex);
    }
  }
  return res;
}

Fixed version (ground truth):
/** 
 * Decompiles .class files and nested archives in the given archive, as allowed by the given filter. <p> Nested archives will be decompiled into directories matching the name of the archive, e.g. <code>foo.ear/bar.jar/src/com/foo/bar/Baz.java</code>. <p> Required directories will be created as needed.
 * @param archive The archive containing source files and archives.
 * @param outputDir The directory where decompiled .java files will be placed.
 * @param filter Decides which classes will be decompiled.
 * @returns Result with all decompilation failures. Never throws.
 */
public DecompilationResult decompileArchive(File archive,File outputDir,Filter<ZipEntry> filter) throws DecompilationException {
  Checks.checkFileToBeRead(archive,"String_Node_Str");
  Checks.checkDirectoryToBeFilled(outputDir,"String_Node_Str");
  log.info("String_Node_Str" + archive.getAbsolutePath() + "String_Node_Str"+ outputDir.getAbsolutePath()+ "String_Node_Str");
  JarFile jar=loadJar(archive);
  int jarEntryCount=0;
  Enumeration<JarEntry> countEnum=jar.entries();
  while (countEnum.hasMoreElements()) {
    countEnum.nextElement();
    jarEntryCount++;
  }
  DecompilerSettings settings=getDefaultSettings(outputDir);
  settings.setTypeLoader(new CompositeTypeLoader(new JarTypeLoader(jar),settings.getTypeLoader()));
  MetadataSystem metadataSystem=new NoRetryMetadataSystem(settings.getTypeLoader());
  int classesDecompiled=0;
  DecompilationResult res=new DecompilationResult();
  Filter.Result filterRes=Filter.Result.ACCEPT;
  int current=0;
  final Enumeration<JarEntry> entries=jar.entries();
  while (entries.hasMoreElements()) {
    final JarEntry entry=entries.nextElement();
    current++;
    if (current % 100 == 0) {
      log.info("String_Node_Str" + current + "String_Node_Str"+ jarEntryCount);
    }
    if (filter != null)     filterRes=filter.decide(entry);
    if (filterRes == Filter.Result.REJECT)     continue;
    if (filterRes == Filter.Result.STOP)     break;
    final String name=entry.getName();
    if (!name.endsWith("String_Node_Str"))     continue;
    final String typeName=StringUtils.removeEnd(name,"String_Node_Str");
    try {
      DecompileExecutor t=new DecompileExecutor(metadataSystem,typeName);
      t.start();
      t.join(60000L);
      if (!t.success) {
        t.cancelDecompilation();
        throw new RuntimeException("String_Node_Str",t.e);
      }
      File outputFile=t.outputFile;
      if (outputFile != null)       res.addDecompiled(name,outputFile.getAbsolutePath());
      if (++classesDecompiled % 100 == 0)       metadataSystem=new NoRetryMetadataSystem(settings.getTypeLoader());
    }
 catch (    Throwable th) {
      String msg="String_Node_Str" + archive.getPath() + "String_Node_Str"+ name+ "String_Node_Str"+ th.getMessage();
      DecompilationFailure ex=new DecompilationFailure(msg,name,th);
      log.log(Level.SEVERE,msg,ex);
      res.addFailure(ex);
    }
  }
  return res;
}