Program: 70982
Project: 70982
Buggy source:
public void componentChanged(ComponentChangeEvent e){
  if (e.getCode() == ComponentChangeEvent.Code.STRUCTURE_CHANGED || e.getCode() == ComponentChangeEvent.Code.DYNAMIC_ACTIVITY_CHANGED) {
    boolean invalidateWaypoints=false;
    RootModel root=getRootModel();
    if (root != null) {
      invalidateWaypoints=changeAffectsWaypoints(root,e);
      if (invalidateWaypoints) {
        root.getWayPoints().invalidateAfterTime(0);
      }
    }
    ModelComponent c=e.getComponent();
    if (myTimeline != null) {
      if (root != null && c == root.getWayPoints()) {
        myTimeline.requestUpdateWidgets();
      }
 else {
        myTimeline.requestUpdateDisplay();
      }
    }
    if (e.getCode() == ComponentChangeEvent.Code.STRUCTURE_CHANGED) {
      if (c != null && c instanceof CompositeComponent && myFrame != null) {
        myFrame.getNavPanel().updateStructure(c);
        if (root != null && (c == root.getInputProbes() || c == root.getOutputProbes())) {
          myTimeline.updateProbes();
        }
      }
    }
    if (invalidateWaypoints && !myScheduler.isPlaying()) {
      myScheduler.invalidateInitialState();
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.NAME_CHANGED) {
    ModelComponent c=e.getComponent();
    if (c.getParent() != null && myFrame != null) {
      myFrame.getNavPanel().updateStructure(c.getParent());
    }
 else {
      myFrame.getNavPanel().updateStructure(c);
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.PROPERTY_CHANGED) {
    PropertyChangeEvent pe=(PropertyChangeEvent)e;
    ModelComponent c=e.getComponent();
    if (c == getRootModel()) {
      if (pe.getPropertyName().equals("String_Node_Str")) {
        doSetMaxStep(getRootModel().getMaxStepSize());
      }
 else       if (pe.getPropertyName().equals("String_Node_Str")) {
        if (myViewerManager != null) {
          myViewerManager.resetViewers(getRootModel().getDefaultViewOrientation());
        }
      }
    }
 else     if (pe.getPropertyName().startsWith("String_Node_Str")) {
      if (myFrame != null) {
        myFrame.getNavPanel().updateStructure(e.getComponent());
      }
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.GEOMETRY_CHANGED) {
    if (!getScheduler().isPlaying()) {
      rerender();
    }
  }
}

Fixed version (ground truth):
public void componentChanged(ComponentChangeEvent e){
  if (e.getCode() == ComponentChangeEvent.Code.STRUCTURE_CHANGED || e.getCode() == ComponentChangeEvent.Code.DYNAMIC_ACTIVITY_CHANGED) {
    boolean invalidateWaypoints=false;
    RootModel root=getRootModel();
    if (root != null) {
      invalidateWaypoints=changeAffectsWaypoints(root,e);
      if (invalidateWaypoints) {
        root.getWayPoints().invalidateAfterTime(0);
      }
    }
    ModelComponent c=e.getComponent();
    if (myTimeline != null) {
      if (root != null && c == root.getWayPoints()) {
        myTimeline.requestUpdateWidgets();
      }
 else {
        myTimeline.requestUpdateDisplay();
      }
    }
    if (e.getCode() == ComponentChangeEvent.Code.STRUCTURE_CHANGED) {
      if (c != null && c instanceof CompositeComponent && myFrame != null) {
        myFrame.getNavPanel().updateStructure(c);
        if (root != null && (c == root.getInputProbes() || c == root.getOutputProbes())) {
          myTimeline.updateProbes();
        }
      }
    }
    if (invalidateWaypoints && !myScheduler.isPlaying()) {
      myScheduler.invalidateInitialState();
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.NAME_CHANGED) {
    ModelComponent c=e.getComponent();
    if (myFrame != null) {
      if (c.getParent() != null) {
        myFrame.getNavPanel().updateStructure(c.getParent());
      }
 else {
        myFrame.getNavPanel().updateStructure(c);
      }
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.PROPERTY_CHANGED) {
    PropertyChangeEvent pe=(PropertyChangeEvent)e;
    ModelComponent c=e.getComponent();
    if (c == getRootModel()) {
      if (pe.getPropertyName().equals("String_Node_Str")) {
        doSetMaxStep(getRootModel().getMaxStepSize());
      }
 else       if (pe.getPropertyName().equals("String_Node_Str")) {
        if (myViewerManager != null) {
          myViewerManager.resetViewers(getRootModel().getDefaultViewOrientation());
        }
      }
    }
 else     if (pe.getPropertyName().startsWith("String_Node_Str")) {
      if (myFrame != null) {
        myFrame.getNavPanel().updateStructure(e.getComponent());
      }
    }
  }
 else   if (e.getCode() == ComponentChangeEvent.Code.GEOMETRY_CHANGED) {
    if (!getScheduler().isPlaying()) {
      rerender();
    }
  }
}