Program: 73871
Project: 73871
Buggy source:
public double _getWCET() throws IllegalActionException {
  double wcet=0;
  double actorFrequency=0;
  double actorWCET=0;
  int actorCount=0;
  CodeGeneratorHelper directorHelper;
  for (  Actor actor : (List<Actor>)((TypedCompositeActor)this.getContainer()).deepEntityList()) {
    actorCount++;
    Attribute frequency=((Entity)actor).getAttribute("String_Node_Str");
    ptolemy.actor.Director dd=actor.getDirector();
    Attribute WCET=((Entity)actor).getAttribute("String_Node_Str");
    if (!(actor instanceof ptolemy.domains.giotto.lib.GiottoError)) {
      if (actor instanceof CompositeActor) {
        if (_debugging) {
        }
        Director dir=actor.getDirector();
        if (_debugging) {
        }
        if (dir == null) {
          if (_debugging) {
          }
        }
 else {
          double dummyWCET=0.0011;
          Attribute dirWCET=dir.getAttribute("String_Node_Str");
          if (dirWCET != null) {
            dummyWCET=((DoubleToken)((Variable)dirWCET).getToken()).doubleValue();
          }
          if (_debugging) {
          }
          wcet+=dummyWCET;
        }
      }
 else {
        if (WCET == null) {
          actorWCET=0.0;
        }
 else {
          try {
            actorWCET=((DoubleToken)((Variable)WCET).getToken()).doubleValue();
          }
 catch (          Exception e2) {
            actorWCET=((IntToken)((Variable)WCET).getToken()).intValue();
          }
        }
        if (frequency == null) {
          actorFrequency=1;
        }
 else {
          actorFrequency=((IntToken)((Variable)frequency).getToken()).intValue();
        }
        wcet+=(actorFrequency * actorWCET);
      }
    }
    if (_debugging) {
    }
  }
  return wcet;
}

Fixed version (ground truth):
/** 
 * Returns the WCET seen by the director
 */
public double _getWCET() throws IllegalActionException {
  double wcet=0;
  double actorFrequency=0;
  double actorWCET=0;
  int actorCount=0;
  CodeGeneratorHelper directorHelper;
  for (  Actor actor : (List<Actor>)((TypedCompositeActor)this.getContainer()).deepEntityList()) {
    actorCount++;
    Attribute frequency=((Entity)actor).getAttribute("String_Node_Str");
    ptolemy.actor.Director dd=actor.getDirector();
    Attribute WCET=((Entity)actor).getAttribute("String_Node_Str");
    if (!(actor instanceof ptolemy.domains.giotto.lib.GiottoError)) {
      if (actor instanceof CompositeActor) {
        if (_debugging) {
        }
        Director dir=actor.getDirector();
        if (_debugging) {
        }
        if (dir == null) {
          if (_debugging) {
          }
        }
 else {
          double dummyWCET=0.0011;
          Attribute dirWCET=dir.getAttribute("String_Node_Str");
          if (dirWCET != null) {
            dummyWCET=((DoubleToken)((Variable)dirWCET).getToken()).doubleValue();
          }
          if (_debugging) {
          }
          wcet+=dummyWCET;
        }
      }
 else {
        if (WCET == null) {
          actorWCET=0.0;
        }
 else {
          try {
            actorWCET=((DoubleToken)((Variable)WCET).getToken()).doubleValue();
          }
 catch (          Exception e2) {
            actorWCET=((IntToken)((Variable)WCET).getToken()).intValue();
          }
        }
        if (frequency == null) {
          actorFrequency=1;
        }
 else {
          actorFrequency=((IntToken)((Variable)frequency).getToken()).intValue();
        }
        wcet+=(actorFrequency * actorWCET);
      }
    }
    if (_debugging) {
    }
  }
  return wcet;
}