Program: 65959
Project: 65959
Buggy source:
/** 
 * Updates chart element Scale.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @param checkVisible indicates if still checking visible of chart element before updating properties of chart element.
 * @generated Don't change this method manually.
 */
public void updateScale(String name,EObject eParentObj,Scale eObj,Scale eRefObj,Scale eDefObj,boolean eDefOverride,boolean checkVisible){
  if (eObj == null) {
    if (eRefObj != null) {
      eObj=eRefObj.copyInstance();
      ChartElementUtil.setEObjectAttribute(eParentObj,name,eObj,false);
    }
 else     if (eDefOverride && eDefObj != null) {
      eObj=eDefObj.copyInstance();
      ChartElementUtil.setEObjectAttribute(eParentObj,name,eObj,false);
      return;
    }
  }
  if (eObj == null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (!eObj.isSetStep()) {
    if (eRefObj != null && eRefObj.isSetStep()) {
      eObj.setStep(eRefObj.getStep());
    }
 else     if (eDefObj != null && eDefObj.isSetStep()) {
      eObj.setStep(eDefObj.getStep());
    }
  }
  if (!eObj.isSetUnit()) {
    if (eRefObj != null && eRefObj.isSetUnit()) {
      eObj.setUnit(eRefObj.getUnit());
    }
 else     if (eDefObj != null && eDefObj.isSetUnit()) {
      eObj.setUnit(eDefObj.getUnit());
    }
  }
  if (!eObj.isSetMinorGridsPerUnit()) {
    if (eRefObj != null && eRefObj.isSetMinorGridsPerUnit()) {
      eObj.setMinorGridsPerUnit(eRefObj.getMinorGridsPerUnit());
    }
 else     if (eDefObj != null && eDefObj.isSetMinorGridsPerUnit()) {
      eObj.setMinorGridsPerUnit(eDefObj.getMinorGridsPerUnit());
    }
  }
  if (!eObj.isSetStepNumber()) {
    if (eRefObj != null && eRefObj.isSetStepNumber()) {
      eObj.setStepNumber(eRefObj.getStepNumber());
    }
 else     if (eDefObj != null && eDefObj.isSetStepNumber()) {
      eObj.setStepNumber(eDefObj.getStepNumber());
    }
  }
  if (!eObj.isSetShowOutside()) {
    if (eRefObj != null && eRefObj.isSetShowOutside()) {
      eObj.setShowOutside(eRefObj.isShowOutside());
    }
 else     if (eDefObj != null && eDefObj.isSetShowOutside()) {
      eObj.setShowOutside(eDefObj.isShowOutside());
    }
  }
  if (!eObj.isSetTickBetweenCategories()) {
    if (eRefObj != null && eRefObj.isSetTickBetweenCategories()) {
      eObj.setTickBetweenCategories(eRefObj.isTickBetweenCategories());
    }
 else     if (eDefObj != null && eDefObj.isSetTickBetweenCategories()) {
      eObj.setTickBetweenCategories(eDefObj.isTickBetweenCategories());
    }
  }
  if (!eObj.isSetAutoExpand()) {
    if (eRefObj != null && eRefObj.isSetAutoExpand()) {
      eObj.setAutoExpand(eRefObj.isAutoExpand());
    }
 else     if (eDefObj != null && eDefObj.isSetAutoExpand()) {
      eObj.setAutoExpand(eDefObj.isAutoExpand());
    }
  }
  if (!eObj.isSetMajorGridsStepNumber()) {
    if (eRefObj != null && eRefObj.isSetMajorGridsStepNumber()) {
      eObj.setMajorGridsStepNumber(eRefObj.getMajorGridsStepNumber());
    }
 else     if (eDefObj != null && eDefObj.isSetMajorGridsStepNumber()) {
      eObj.setMajorGridsStepNumber(eDefObj.getMajorGridsStepNumber());
    }
  }
  if (!eObj.isSetFactor()) {
    if (eRefObj != null && eRefObj.isSetFactor()) {
      eObj.setFactor(eRefObj.getFactor());
    }
 else     if (eDefObj != null && eDefObj.isSetFactor()) {
      eObj.setFactor(eDefObj.getFactor());
    }
  }
  if (eRefObj != null && eRefObj.getMin() != null) {
    eObj.setMin(eRefObj.getMin());
  }
 else   if (eDefObj != null && eDefObj.getMin() != null) {
    eObj.setMin(eDefObj.getMin());
  }
  if (eRefObj != null && eRefObj.getMax() != null) {
    eObj.setMax(eRefObj.getMax());
  }
 else   if (eDefObj != null && eDefObj.getMax() != null) {
    eObj.setMax(eDefObj.getMax());
  }
}

Fixed version (ground truth):
/** 
 * Updates chart element Scale.
 * @param eObj chart element object.
 * @param eRefObj reference chart element object.
 * @param eDefObj default chart element object.
 * @param eDefOverride indicates if using default object to override target object if target is null.
 * @param checkVisible indicates if still checking visible of chart element before updating properties of chart element.
 * @generated Don't change this method manually.
 */
public void updateScale(String name,EObject eParentObj,Scale eObj,Scale eRefObj,Scale eDefObj,boolean eDefOverride,boolean checkVisible){
  if (eObj == null) {
    if (eRefObj != null) {
      eObj=eRefObj.copyInstance();
      ChartElementUtil.setEObjectAttribute(eParentObj,name,eObj,false);
    }
 else     if (eDefOverride && eDefObj != null) {
      eObj=eDefObj.copyInstance();
      ChartElementUtil.setEObjectAttribute(eParentObj,name,eObj,false);
      return;
    }
  }
  if (eObj == null || (eRefObj == null && eDefObj == null)) {
    return;
  }
  if (!eObj.isSetStep()) {
    if (eRefObj != null && eRefObj.isSetStep()) {
      eObj.setStep(eRefObj.getStep());
    }
 else     if (eDefObj != null && eDefObj.isSetStep()) {
      eObj.setStep(eDefObj.getStep());
    }
  }
  if (!eObj.isSetUnit()) {
    if (eRefObj != null && eRefObj.isSetUnit()) {
      eObj.setUnit(eRefObj.getUnit());
    }
 else     if (eDefObj != null && eDefObj.isSetUnit()) {
      eObj.setUnit(eDefObj.getUnit());
    }
  }
  if (!eObj.isSetMinorGridsPerUnit()) {
    if (eRefObj != null && eRefObj.isSetMinorGridsPerUnit()) {
      eObj.setMinorGridsPerUnit(eRefObj.getMinorGridsPerUnit());
    }
 else     if (eDefObj != null && eDefObj.isSetMinorGridsPerUnit()) {
      eObj.setMinorGridsPerUnit(eDefObj.getMinorGridsPerUnit());
    }
  }
  if (!eObj.isSetStepNumber()) {
    if (eRefObj != null && eRefObj.isSetStepNumber()) {
      eObj.setStepNumber(eRefObj.getStepNumber());
    }
 else     if (eDefObj != null && eDefObj.isSetStepNumber()) {
      eObj.setStepNumber(eDefObj.getStepNumber());
    }
  }
  if (!eObj.isSetShowOutside()) {
    if (eRefObj != null && eRefObj.isSetShowOutside()) {
      eObj.setShowOutside(eRefObj.isShowOutside());
    }
 else     if (eDefObj != null && eDefObj.isSetShowOutside()) {
      eObj.setShowOutside(eDefObj.isShowOutside());
    }
  }
  if (!eObj.isSetTickBetweenCategories()) {
    if (eRefObj != null && eRefObj.isSetTickBetweenCategories()) {
      eObj.setTickBetweenCategories(eRefObj.isTickBetweenCategories());
    }
 else     if (eDefObj != null && eDefObj.isSetTickBetweenCategories()) {
      eObj.setTickBetweenCategories(eDefObj.isTickBetweenCategories());
    }
  }
  if (!eObj.isSetAutoExpand()) {
    if (eRefObj != null && eRefObj.isSetAutoExpand()) {
      eObj.setAutoExpand(eRefObj.isAutoExpand());
    }
 else     if (eDefObj != null && eDefObj.isSetAutoExpand()) {
      eObj.setAutoExpand(eDefObj.isAutoExpand());
    }
  }
  if (!eObj.isSetMajorGridsStepNumber()) {
    if (eRefObj != null && eRefObj.isSetMajorGridsStepNumber()) {
      eObj.setMajorGridsStepNumber(eRefObj.getMajorGridsStepNumber());
    }
 else     if (eDefObj != null && eDefObj.isSetMajorGridsStepNumber()) {
      eObj.setMajorGridsStepNumber(eDefObj.getMajorGridsStepNumber());
    }
  }
  if (!eObj.isSetFactor()) {
    if (eRefObj != null && eRefObj.isSetFactor()) {
      eObj.setFactor(eRefObj.getFactor());
    }
 else     if (eDefObj != null && eDefObj.isSetFactor()) {
      eObj.setFactor(eDefObj.getFactor());
    }
  }
  if (eObj.getMin() == null) {
    if (eRefObj != null && eRefObj.getMin() != null) {
      eObj.setMin(eRefObj.getMin().copyInstance());
    }
 else     if (eDefObj != null && eDefObj.getMin() != null) {
      eObj.setMin(eDefObj.getMin().copyInstance());
    }
  }
  if (eObj.getMax() == null) {
    if (eRefObj != null && eRefObj.getMax() != null) {
      eObj.setMax(eRefObj.getMax().copyInstance());
    }
 else     if (eDefObj != null && eDefObj.getMax() != null) {
      eObj.setMax(eDefObj.getMax().copyInstance());
    }
  }
}