Program: 59049
Project: 59049
Buggy source:
private void initializeNewPathways(final GL gl){
  if (!iAlUninitializedPathwayIDs.isEmpty() && arSlerpActions.isEmpty()) {
    int iTmpPathwayID=iAlUninitializedPathwayIDs.get(0);
    if (!generalManager.getPathwayManager().isPathwayVisible(iTmpPathwayID)) {
      ArrayList<Integer> iAlSetIDs=new ArrayList<Integer>();
      for (      ISet tmpSet : alSets) {
        iAlSetIDs.add(tmpSet.getID());
      }
      CmdCreateGLPathway cmdPathway=(CmdCreateGLPathway)generalManager.getCommandManager().createCommandByType(ECommandType.CREATE_GL_PATHWAY_3D);
      cmdPathway.setAttributes(iTmpPathwayID,iAlSetIDs,EProjectionMode.ORTHOGRAPHIC,-4,4,4,-4,-20,20);
      cmdPathway.doCommand();
      GLPathway pathway=(GLPathway)cmdPathway.getCreatedObject();
      int iGeneratedViewID=pathway.getID();
      ArrayList<Integer> arMediatorIDs=new ArrayList<Integer>();
      arMediatorIDs.add(iGeneratedViewID);
      generalManager.getEventPublisher().addSendersAndReceiversToMediator(generalManager.getEventPublisher().getItem(iMediatorID),arMediatorIDs,arMediatorIDs,EMediatorType.SELECTION_MEDIATOR,EMediatorUpdateType.MEDIATOR_DEFAULT);
      if (underInteractionLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,underInteractionLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,underInteractionLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.MEDIUM);
        pathway.broadcastElements(ESelectionType.NORMAL);
      }
 else       if (stackLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,stackLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,stackLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.LOW);
        pathway.broadcastElements(ESelectionType.NORMAL);
      }
 else       if (poolLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,poolLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,poolLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.VERY_LOW);
      }
 else {
        generalManager.getLogger().log(Level.SEVERE,"String_Node_Str");
        iAlUninitializedPathwayIDs.remove(0);
        return;
      }
      spawnLayer.addElement(iGeneratedViewID);
    }
    iAlUninitializedPathwayIDs.remove(0);
    if (iAlUninitializedPathwayIDs.isEmpty())     enableBusyMode(false);
 else     enableBusyMode(true);
    generalManager.getViewGLCanvasManager().getConnectedElementRepresentationManager().clear();
  }
}

Fixed version (ground truth):
private void initializeNewPathways(final GL gl){
  if (!iAlUninitializedPathwayIDs.isEmpty() && arSlerpActions.isEmpty()) {
    int iTmpPathwayID=iAlUninitializedPathwayIDs.get(0);
    if (!generalManager.getPathwayManager().isPathwayVisible(iTmpPathwayID)) {
      ArrayList<Integer> iAlSetIDs=new ArrayList<Integer>();
      for (      ISet tmpSet : alSets) {
        iAlSetIDs.add(tmpSet.getID());
      }
      CmdCreateGLPathway cmdPathway=(CmdCreateGLPathway)generalManager.getCommandManager().createCommandByType(ECommandType.CREATE_GL_PATHWAY_3D);
      cmdPathway.setAttributes(iTmpPathwayID,iAlSetIDs,EProjectionMode.ORTHOGRAPHIC,-4,4,4,-4,-20,20);
      cmdPathway.doCommand();
      GLPathway pathway=(GLPathway)cmdPathway.getCreatedObject();
      int iGeneratedViewID=pathway.getID();
      ArrayList<Integer> arMediatorIDs=new ArrayList<Integer>();
      arMediatorIDs.add(iGeneratedViewID);
      generalManager.getEventPublisher().addSendersAndReceiversToMediator(generalManager.getEventPublisher().getItem(iMediatorID),arMediatorIDs,arMediatorIDs,EMediatorType.SELECTION_MEDIATOR,EMediatorUpdateType.MEDIATOR_DEFAULT);
      if (underInteractionLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,underInteractionLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,underInteractionLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.MEDIUM);
        pathway.broadcastElements(ESelectionType.ADD);
      }
 else       if (stackLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,stackLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,stackLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.LOW);
        pathway.broadcastElements(ESelectionType.ADD);
      }
 else       if (poolLayer.containsElement(-1)) {
        SlerpAction slerpActionTransition=new SlerpAction(iGeneratedViewID,spawnLayer,poolLayer);
        arSlerpActions.add(slerpActionTransition);
        pathway.initRemote(gl,iUniqueID,poolLayer,pickingTriggerMouseAdapter,this);
        pathway.setDetailLevel(EDetailLevel.VERY_LOW);
      }
 else {
        generalManager.getLogger().log(Level.SEVERE,"String_Node_Str");
        iAlUninitializedPathwayIDs.remove(0);
        return;
      }
      spawnLayer.addElement(iGeneratedViewID);
    }
    iAlUninitializedPathwayIDs.remove(0);
    if (iAlUninitializedPathwayIDs.isEmpty())     enableBusyMode(false);
 else     enableBusyMode(true);
    generalManager.getViewGLCanvasManager().getConnectedElementRepresentationManager().clear();
  }
}