Program: 72945
Project: 72945
Buggy source:
/** 
 * Schedule a new actor for execution. Find the const actor in the _model that is mapped to this actor and trigger a firing of that one, if the actor is not already in execution. If the actor finished execution, return zero time, otherwise return the next time the model has something to do.
 * @param actor The actor to be scheduled.
 * @param currentPlatformTime The current platform time.
 * @param deadline The deadline of the event.
 * @param executionTime The execution time of the actor.
 * @return Relative time when this Scheduler has to be executedagain.
 * @exception IllegalActionException Thrown if actor paramaters suchas execution time or priority cannot be read.
 */
protected Time _schedule(Actor actor,Time currentPlatformTime,Time deadline,Time executionTime) throws IllegalActionException {
  _lastActorFinished=false;
  getDirector().setModelTime(getExecutiveDirector().localClock.getLocalTime());
  if (!_currentlyExecuting.contains(actor)) {
    event((NamedObj)actor,getExecutiveDirector().localClock.getLocalTime().getDoubleValue(),ExecutionEventType.START);
    ResourceMappingInputPort requestPort=(ResourceMappingInputPort)getEntity(_requestPorts.get(actor));
    if (requestPort != null) {
      RecordToken recordToken=new RecordToken(new String[]{"String_Node_Str","String_Node_Str"},new Token[]{new ObjectToken(actor),new DoubleToken(executionTime.getDoubleValue())});
      requestPort.value.setToken(recordToken);
      getDirector().fireAtCurrentTime(requestPort);
      getExecutiveDirector().fireAt(this,getDirector().getModelTime());
      _currentlyExecuting.add(actor);
    }
 else {
      throw new IllegalActionException(this,"String_Node_Str" + _requestPorts.get(actor));
    }
  }
  return Time.POSITIVE_INFINITY;
}

Fixed version (ground truth):
/** 
 * Schedule a new actor for execution. Find the const actor in the _model that is mapped to this actor and trigger a firing of that one, if the actor is not already in execution. If the actor finished execution, return zero time, otherwise return the next time the model has something to do.
 * @param actor The actor to be scheduled.
 * @param currentPlatformTime The current platform time.
 * @param deadline The deadline of the event.
 * @param executionTime The execution time of the actor.
 * @return Relative time when this Scheduler has to be executedagain.
 * @exception IllegalActionException Thrown if actor paramaters suchas execution time or priority cannot be read.
 */
protected Time _schedule(Actor actor,Time currentPlatformTime,Time deadline,Time executionTime) throws IllegalActionException {
  _lastActorFinished=false;
  getDirector().setModelTime(getExecutiveDirector().localClock.getLocalTime());
  if (!_currentlyExecuting.contains(actor)) {
    event((NamedObj)actor,getExecutiveDirector().localClock.getLocalTime().getDoubleValue(),ExecutionEventType.START);
    if (_requestPorts.get(actor) == null) {
      throw new IllegalActionException(this,"String_Node_Str" + actor + "String_Node_Str"+ "String_Node_Str");
    }
    ResourceMappingInputPort requestPort=(ResourceMappingInputPort)getEntity(_requestPorts.get(actor));
    if (requestPort != null) {
      RecordToken recordToken=new RecordToken(new String[]{"String_Node_Str","String_Node_Str"},new Token[]{new ObjectToken(actor),new DoubleToken(executionTime.getDoubleValue())});
      requestPort.value.setToken(recordToken);
      getDirector().fireAtCurrentTime(requestPort);
      getExecutiveDirector().fireAt(this,getDirector().getModelTime());
      _currentlyExecuting.add(actor);
    }
 else {
      throw new IllegalActionException(this,"String_Node_Str" + _requestPorts.get(actor));
    }
  }
  return Time.POSITIVE_INFINITY;
}