Program: 40928
Project: 40928
Buggy source:
/** 
 * Initializes Property variables and mappings for a TemplateBuildPlan which handles a RelationshipTemplate
 * @param map the PropertyMap to save the result to
 * @param templatePlan a TemplateBuildPlan which handles a RelationshipTemplate
 */
private void initPropsAsVarsInRelationship(final PropertyMap map,final BPELScopeActivity templatePlan){
  final AbstractRelationshipTemplate relationshipTemplate=templatePlan.getRelationshipTemplate();
  if (relationshipTemplate.getProperties() != null) {
    final Element propertyElement=relationshipTemplate.getProperties().getDOMElement();
    for (int i=0; i < propertyElement.getChildNodes().getLength(); i++) {
      if (propertyElement.getChildNodes().item(i).getNodeType() == Node.TEXT_NODE) {
        continue;
      }
      final String propName=propertyElement.getChildNodes().item(i).getLocalName();
      final String propVarName=relationshipTemplate.getId() + "String_Node_Str" + propertyElement.getChildNodes().item(i).getLocalName();
      map.addPropertyMapping(relationshipTemplate.getId(),propName,"String_Node_Str" + propVarName);
      String value="String_Node_Str";
      for (int j=0; j < propertyElement.getChildNodes().item(i).getChildNodes().getLength(); j++) {
        if (propertyElement.getChildNodes().item(i).getChildNodes().item(j).getNodeType() == Node.TEXT_NODE) {
          value+=propertyElement.getChildNodes().item(i).getChildNodes().item(j).getNodeValue();
        }
      }
      PropertyVariableInitializer.LOG.debug("String_Node_Str" + propVarName);
      PropertyVariableInitializer.LOG.debug("String_Node_Str" + value);
      this.planHandler.addPropertyVariable(propVarName,templatePlan.getBuildPlan());
      if (!value.trim().isEmpty() && !value.trim().equals("String_Node_Str")) {
        this.planHandler.initializePropertyVariable(propVarName,value,templatePlan.getBuildPlan());
      }
    }
  }
}

Fixed version (ground truth):
/** 
 * Initializes Property variables and mappings for a TemplateBuildPlan which handles a RelationshipTemplate
 * @param map the PropertyMap to save the result to
 * @param templatePlan a TemplateBuildPlan which handles a RelationshipTemplate
 */
private void initPropsAsVarsInRelationship(final PropertyMap map,final BPELScopeActivity templatePlan){
  final AbstractRelationshipTemplate relationshipTemplate=templatePlan.getRelationshipTemplate();
  if (relationshipTemplate.getProperties() != null) {
    final Element propertyElement=relationshipTemplate.getProperties().getDOMElement();
    for (int i=0; i < propertyElement.getChildNodes().getLength(); i++) {
      if (propertyElement.getChildNodes().item(i).getNodeType() == Node.TEXT_NODE) {
        continue;
      }
      final String propName=propertyElement.getChildNodes().item(i).getLocalName();
      final String propVarName=relationshipTemplate.getId().replace("String_Node_Str","String_Node_Str") + "String_Node_Str" + propertyElement.getChildNodes().item(i).getLocalName();
      map.addPropertyMapping(relationshipTemplate.getId(),propName,"String_Node_Str" + propVarName);
      String value="String_Node_Str";
      for (int j=0; j < propertyElement.getChildNodes().item(i).getChildNodes().getLength(); j++) {
        if (propertyElement.getChildNodes().item(i).getChildNodes().item(j).getNodeType() == Node.TEXT_NODE) {
          value+=propertyElement.getChildNodes().item(i).getChildNodes().item(j).getNodeValue();
        }
      }
      PropertyVariableInitializer.LOG.debug("String_Node_Str" + propVarName);
      PropertyVariableInitializer.LOG.debug("String_Node_Str" + value);
      this.planHandler.addPropertyVariable(propVarName,templatePlan.getBuildPlan());
      if (!value.trim().isEmpty() && !value.trim().equals("String_Node_Str")) {
        this.planHandler.initializePropertyVariable(propVarName,value,templatePlan.getBuildPlan());
      }
    }
  }
}