Program: 121352
Project: 121352
Buggy source:
@Override public void reloadComponent(IComponent component,Map<String,Object> parameters){
  reloadingComponent=true;
  currentStatus=0;
  Object obj=parameters.get(INode.RELOAD_PARAMETER_ELEMENT_PARAMETERS);
  Map<String,Object> storeValueMap=storeValue(obj);
  init(component);
  IElementParameter param=getElementParameter(EParameterName.REPOSITORY_ALLOW_AUTO_SWITCH.getName());
  if (param != null) {
    param.setValue(Boolean.TRUE);
  }
  if (obj != null) {
    List<? extends IElementParameter> oldElementParameters=(List<? extends IElementParameter>)obj;
    for (    IElementParameter sourceParam : oldElementParameters) {
      IElementParameter targetParam=getElementParameter(sourceParam.getName());
      if (targetParam != null) {
        if (sourceParam.getName().equals(EParameterName.LABEL.getName()) && (sourceParam.getValue() == null || "String_Node_Str".equals(sourceParam.getValue()))) {
          setPropertyValue(sourceParam.getName(),component.getProcess().getName());
        }
 else {
          setPropertyValue(sourceParam.getName(),sourceParam.getValue());
        }
        if (targetParam.getFieldType() == EParameterFieldType.TABLE) {
          targetParam.setListItemsValue(sourceParam.getListItemsValue());
        }
        for (        String name : targetParam.getChildParameters().keySet()) {
          IElementParameter targetChildParam=targetParam.getChildParameters().get(name);
          IElementParameter sourceChildParam=sourceParam.getChildParameters().get(name);
          if (sourceChildParam == null) {
            continue;
          }
          String pname=sourceParam.getName() + "String_Node_Str" + sourceChildParam.getName();
          if (storeValueMap.get(pname) != null) {
            setPropertyValue(pname,storeValueMap.get(pname));
          }
 else {
            setPropertyValue(pname,sourceChildParam.getValue());
          }
          if (targetChildParam.getFieldType() == EParameterFieldType.TABLE) {
            targetChildParam.setListItemsValue(sourceChildParam.getListItemsValue());
          }
 else           if (targetChildParam.getFieldType() == EParameterFieldType.CONNECTION_LIST) {
            if (((getPropertyValue(pname) == null || getPropertyValue(pname).toString().length() == 0)) && component.getProcess() instanceof IProcess2 && storeValueMap.containsKey(sourceParam.getName())&& !storeValueMap.containsKey(pname)) {
              storeConn(sourceParam,pname);
            }
          }
        }
      }
    }
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_METADATA_LIST);
  if (obj != null) {
    setMetadataList((List<IMetadataTable>)obj);
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_EXTERNAL_BYTES_DATA);
  if (obj != null && isExternalNode()) {
    if (obj instanceof IExternalData) {
      getExternalNode().setExternalData((IExternalData)obj);
    }
    getExternalNode().initialize();
  }
  boolean isJobletNode=false;
  if (PluginChecker.isJobLetPluginLoaded()) {
    IJobletProviderService service=(IJobletProviderService)GlobalServiceRegister.getDefault().getService(IJobletProviderService.class);
    if (service != null && service.isJobletComponent(this)) {
      isJobletNode=true;
    }
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_CONNECTORS);
  if (obj != null) {
    List<? extends INodeConnector> connectors=(List<? extends INodeConnector>)obj;
    if (isJobletNode) {
      listConnector=connectors;
    }
 else {
      for (      INodeConnector currentConnector : listConnector) {
        for (        INodeConnector connector : connectors) {
          if (currentConnector.getName().equals(connector.getName())) {
            currentConnector.setCurLinkNbInput(connector.getCurLinkNbInput());
            currentConnector.setCurLinkNbOutput(connector.getCurLinkNbOutput());
            break;
          }
        }
      }
    }
  }
  reloadingComponent=false;
}

Fixed version (ground truth):
@Override public void reloadComponent(IComponent component,Map<String,Object> parameters){
  reloadingComponent=true;
  currentStatus=0;
  Object obj=parameters.get(INode.RELOAD_PARAMETER_ELEMENT_PARAMETERS);
  Map<String,Object> storeValueMap=storeValue(obj);
  init(component);
  IElementParameter param=getElementParameter(EParameterName.REPOSITORY_ALLOW_AUTO_SWITCH.getName());
  if (param != null) {
    param.setValue(Boolean.TRUE);
  }
  boolean isJobletNode=false;
  if (PluginChecker.isJobLetPluginLoaded()) {
    IJobletProviderService service=(IJobletProviderService)GlobalServiceRegister.getDefault().getService(IJobletProviderService.class);
    if (service != null && service.isJobletComponent(this)) {
      isJobletNode=true;
    }
  }
  if (obj != null) {
    List<? extends IElementParameter> oldElementParameters=(List<? extends IElementParameter>)obj;
    for (    IElementParameter sourceParam : oldElementParameters) {
      IElementParameter targetParam=getElementParameter(sourceParam.getName());
      String sourceParamName=sourceParam.getName();
      if (isJobletNode && (EParameterName.PROCESS_TYPE_VERSION.getName()).equals(sourceParamName)) {
        Object versionObj=storeValueMap.get(sourceParamName);
        if (versionObj != null && !versionObj.equals(sourceParam.getValue())) {
          sourceParam.setValue(versionObj);
        }
      }
      if (targetParam != null) {
        if (sourceParam.getName().equals(EParameterName.LABEL.getName()) && (sourceParam.getValue() == null || "String_Node_Str".equals(sourceParam.getValue()))) {
          setPropertyValue(sourceParam.getName(),component.getProcess().getName());
        }
 else {
          setPropertyValue(sourceParam.getName(),sourceParam.getValue());
        }
        if (targetParam.getFieldType() == EParameterFieldType.TABLE) {
          targetParam.setListItemsValue(sourceParam.getListItemsValue());
        }
        for (        String name : targetParam.getChildParameters().keySet()) {
          IElementParameter targetChildParam=targetParam.getChildParameters().get(name);
          IElementParameter sourceChildParam=sourceParam.getChildParameters().get(name);
          if (sourceChildParam == null) {
            continue;
          }
          String pname=sourceParam.getName() + "String_Node_Str" + sourceChildParam.getName();
          if (storeValueMap.get(pname) != null) {
            setPropertyValue(pname,storeValueMap.get(pname));
          }
 else {
            setPropertyValue(pname,sourceChildParam.getValue());
          }
          if (targetChildParam.getFieldType() == EParameterFieldType.TABLE) {
            targetChildParam.setListItemsValue(sourceChildParam.getListItemsValue());
          }
 else           if (targetChildParam.getFieldType() == EParameterFieldType.CONNECTION_LIST) {
            if (((getPropertyValue(pname) == null || getPropertyValue(pname).toString().length() == 0)) && component.getProcess() instanceof IProcess2 && storeValueMap.containsKey(sourceParam.getName())&& !storeValueMap.containsKey(pname)) {
              storeConn(sourceParam,pname);
            }
          }
        }
      }
    }
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_METADATA_LIST);
  if (obj != null) {
    setMetadataList((List<IMetadataTable>)obj);
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_EXTERNAL_BYTES_DATA);
  if (obj != null && isExternalNode()) {
    if (obj instanceof IExternalData) {
      getExternalNode().setExternalData((IExternalData)obj);
    }
    getExternalNode().initialize();
  }
  obj=parameters.get(INode.RELOAD_PARAMETER_CONNECTORS);
  if (obj != null) {
    List<? extends INodeConnector> connectors=(List<? extends INodeConnector>)obj;
    if (isJobletNode) {
      listConnector=connectors;
    }
 else {
      for (      INodeConnector currentConnector : listConnector) {
        for (        INodeConnector connector : connectors) {
          if (currentConnector.getName().equals(connector.getName())) {
            currentConnector.setCurLinkNbInput(connector.getCurLinkNbInput());
            currentConnector.setCurLinkNbOutput(connector.getCurLinkNbOutput());
            break;
          }
        }
      }
    }
  }
  reloadingComponent=false;
}