Program: 118005
Project: 118005
Buggy source:
@Override public void checkChangementsAfterEntryModifiedOrAdded(boolean forceEvaluation){
  super.checkChangementsAfterEntryModifiedOrAdded(forceEvaluation);
  if (!getInputTable().isMainConnection() && mapperManager.isAdvancedMap()) {
    boolean stateAtLeastOneHashKey=mapperManager.isTableHasAtLeastOneHashKey(getInputTable());
    if (forceEvaluation || previousStateAtLeastOneHashKey != stateAtLeastOneHashKey) {
      if (stateAtLeastOneHashKey) {
        Object previous=getInputTable().getMatchingMode();
        getInputTable().setMatchingMode(previousMatchingModeSelected);
        Object object=mapperManager.getDefaultSetting().get(MATCH_MODEL_SETTING);
        if (object instanceof IUIMatchingMode[]) {
          IUIMatchingMode[] modes=(IUIMatchingMode[])object;
          if (modes.length == 2) {
            if ((modes[0].equals(previous) || modes[1].equals(previous)) && !modes[0].equals(previousMatchingModeSelected) && !modes[1].equals(previousMatchingModeSelected)) {
              if (changedOptions < 4) {
                changedOptions++;
              }
            }
          }
        }
        previous=getInputTable().isInnerJoin();
        getInputTable().setInnerJoin(previousInnerJoinSelection);
        if (mapperManager.getDefaultSetting().get(JOIN_MODEL_SETTING).equals(previous) && !mapperManager.getDefaultSetting().get(JOIN_MODEL_SETTING).equals(previousInnerJoinSelection)) {
          if (changedOptions < 4) {
            changedOptions++;
          }
        }
        innerJoinCheckItemEditable=true;
        updateViewAfterChangeInnerJoinCheck();
      }
 else {
        TMAP_MATCHING_MODE matchingMode=TMAP_MATCHING_MODE.ALL_ROWS;
        if (getInputTable().getLookupMode() == TMAP_LOOKUP_MODE.CACHE_OR_RELOAD) {
          String errorMessage=Messages.getString("String_Node_Str",getInputTable().getName());
          mapperManager.getUiManager().setStatusBarValues(STATUS.ERROR,errorMessage);
        }
 else {
          mapperManager.getUiManager().setStatusBarValues(STATUS.EMPTY,null);
        }
        Object previous=getInputTable().getMatchingMode();
        getInputTable().setMatchingMode(matchingMode);
        Object object=mapperManager.getDefaultSetting().get(MATCH_MODEL_SETTING);
        if (object instanceof IUIMatchingMode[]) {
          IUIMatchingMode[] modes=(IUIMatchingMode[])object;
          if (modes.length == 2) {
            if (!modes[0].equals(previous) && !modes[1].equals(previous)) {
              if (changedOptions > 0) {
                changedOptions--;
              }
            }
          }
        }
        innerJoinCheckItemEditable=false;
      }
      previousStateAtLeastOneHashKey=stateAtLeastOneHashKey;
    }
    if (!forceEvaluation) {
      condensedItem.setImage(ImageProviderMapper.getImage(getCondencedItemImage(changedOptions)));
    }
    layoutToolBar();
    mapSettingViewerCreator.refresh();
  }
}

Fixed version (ground truth):
@Override public void checkChangementsAfterEntryModifiedOrAdded(boolean forceEvaluation){
  super.checkChangementsAfterEntryModifiedOrAdded(forceEvaluation);
  if (!getInputTable().isMainConnection() && mapperManager.isAdvancedMap()) {
    boolean stateAtLeastOneHashKey=mapperManager.isTableHasAtLeastOneHashKey(getInputTable());
    if (forceEvaluation || previousStateAtLeastOneHashKey != stateAtLeastOneHashKey) {
      if (stateAtLeastOneHashKey) {
        Object previous=getInputTable().getMatchingMode();
        Object object=mapperManager.getDefaultSetting().get(MATCH_MODEL_SETTING);
        if (object instanceof IUIMatchingMode[]) {
          IUIMatchingMode[] modes=(IUIMatchingMode[])object;
          if (modes.length == 2) {
            if ((modes[0].equals(previous) || modes[1].equals(previous)) && !modes[0].equals(previousMatchingModeSelected) && !modes[1].equals(previousMatchingModeSelected)) {
              if (changedOptions < 4) {
                changedOptions++;
              }
            }
          }
        }
        previous=getInputTable().isInnerJoin();
        getInputTable().setInnerJoin(previousInnerJoinSelection);
        if (mapperManager.getDefaultSetting().get(JOIN_MODEL_SETTING).equals(previous) && !mapperManager.getDefaultSetting().get(JOIN_MODEL_SETTING).equals(previousInnerJoinSelection)) {
          if (changedOptions < 4) {
            changedOptions++;
          }
        }
        innerJoinCheckItemEditable=true;
        updateViewAfterChangeInnerJoinCheck();
      }
 else {
        if (getInputTable().getLookupMode() == TMAP_LOOKUP_MODE.CACHE_OR_RELOAD) {
          String errorMessage=Messages.getString("String_Node_Str",getInputTable().getName());
          mapperManager.getUiManager().setStatusBarValues(STATUS.ERROR,errorMessage);
        }
 else {
          mapperManager.getUiManager().setStatusBarValues(STATUS.EMPTY,null);
        }
        Object previous=getInputTable().getMatchingMode();
        Object object=mapperManager.getDefaultSetting().get(MATCH_MODEL_SETTING);
        if (object instanceof IUIMatchingMode[]) {
          IUIMatchingMode[] modes=(IUIMatchingMode[])object;
          if (modes.length == 2) {
            if (!modes[0].equals(previous) && !modes[1].equals(previous)) {
              if (changedOptions > 0) {
                changedOptions--;
              }
            }
          }
        }
        innerJoinCheckItemEditable=false;
      }
      previousStateAtLeastOneHashKey=stateAtLeastOneHashKey;
    }
    if (!forceEvaluation) {
      condensedItem.setImage(ImageProviderMapper.getImage(getCondencedItemImage(changedOptions)));
    }
    checkLookupTableProblems(stateAtLeastOneHashKey);
    mapSettingViewerCreator.refresh();
  }
}