Program: 39650
Project: 39650
Buggy source:
@Override public final void run(TestResult result){
  result.addListener(listener);
  List<Config> configs=new LinkedList<Config>();
  boolean aptEnabled=false;
  try {
    Thread.currentThread().getContextClassLoader().loadClass(APT_INSTRUMENTOR);
    aptEnabled=true;
  }
 catch (  ClassNotFoundException ignore) {
  }
  String testMode=System.getProperty(CHROMATTIC_TEST_MODE);
  if (testMode == null) {
    testMode=MODE_ALL;
  }
  if (MODE_ALL.equals(testMode)) {
    if (aptEnabled) {
      configs.add(new Config(APT_INSTRUMENTOR,false,false,false));
    }
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,false,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,true,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,true));
  }
 else   if (MODE_APT.equals(testMode)) {
    configs.add(new Config(APT_INSTRUMENTOR,false,false,false));
  }
 else   if (MODE_CGLIB.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,false));
  }
 else   if (MODE_CACHE.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,false,false));
  }
 else   if (MODE_HAS_NODE.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,true));
  }
 else   if (MODE_HAS_PROPERTY.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,true,false));
  }
  for (  Config config : configs) {
    this.config=config;
    super.run(result);
  }
  result.removeListener(listener);
}

Fixed version (ground truth):
@Override public final void run(TestResult result){
  result.addListener(listener);
  List<Config> configs=new LinkedList<Config>();
  boolean aptEnabled=false;
  try {
    Thread.currentThread().getContextClassLoader().loadClass(APT_INSTRUMENTOR);
    aptEnabled=true;
  }
 catch (  ClassNotFoundException ignore) {
  }
  String testMode=System.getProperty(CHROMATTIC_TEST_MODE);
  if (testMode == null) {
    testMode=MODE_ALL;
  }
  if (MODE_ALL.equals(testMode)) {
    if (aptEnabled) {
      configs.add(new Config(APT_INSTRUMENTOR,false,false,false));
    }
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,false,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,true,false));
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,true));
  }
 else   if (MODE_APT.equals(testMode)) {
    configs.add(new Config(APT_INSTRUMENTOR,false,false,false));
  }
 else   if (MODE_CGLIB.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,false));
  }
 else   if (MODE_CACHE.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,false,false));
  }
 else   if (MODE_HAS_NODE.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,false,false,true));
  }
 else   if (MODE_HAS_PROPERTY.equals(testMode)) {
    configs.add(new Config(CGLIB_INSTRUMENTOR,true,true,false));
  }
  for (  Config config : configs) {
    this.config=config;
    try {
      super.run(result);
    }
  finally {
      ArrayList<ChromatticSessionImpl> copy=new ArrayList<ChromatticSessionImpl>(sessions);
      sessions.clear();
      for (      ChromatticSession session : copy) {
        if (!session.isClosed()) {
          session.close();
        }
      }
    }
  }
  result.removeListener(listener);
}