Program: 61163
Project: 61163
Buggy source:
@RequestMapping(method=RequestMethod.GET,value="String_Node_Str") public List<SchemaMappingTO> getRoleResourcesMapping(HttpServletResponse response,@PathVariable("String_Node_Str") Long roleId) throws SyncopeClientCompositeErrorException {
  SyncopeRole role=null;
  if (roleId != null) {
    role=syncopeRoleDAO.find(roleId);
  }
  if (role == null) {
    LOG.error("String_Node_Str" + roleId + "String_Node_Str");
    SyncopeClientCompositeErrorException compositeErrorException=new SyncopeClientCompositeErrorException(HttpStatus.BAD_REQUEST);
    SyncopeClientException ex=new SyncopeClientException(SyncopeClientExceptionType.RequiredValuesMissing);
    ex.addElement("String_Node_Str");
    compositeErrorException.addException(ex);
    throw compositeErrorException;
  }
  List<SchemaMappingTO> roleMappings=new ArrayList<SchemaMappingTO>();
  Set<TargetResource> resources=role.getTargetResources();
  List<SchemaMappingTO> resourceMappings=null;
  for (  TargetResource resource : resources) {
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str");
    }
    List<SchemaMapping> schemaMappings=resource.getMappings();
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str"+ schemaMappings+ "String_Node_Str");
    }
    resourceMappings=binder.getSchemaMappingTOs(schemaMappings);
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str"+ resourceMappings+ "String_Node_Str");
    }
    roleMappings.addAll(resourceMappings);
  }
  if (LOG.isDebugEnabled()) {
    LOG.debug("String_Node_Str" + roleMappings);
  }
  return roleMappings;
}

Fixed version (ground truth):
@RequestMapping(method=RequestMethod.GET,value="String_Node_Str") public List<SchemaMappingTO> getRoleResourcesMapping(HttpServletResponse response,@PathVariable("String_Node_Str") Long roleId) throws SyncopeClientCompositeErrorException {
  SyncopeRole role=null;
  if (roleId != null) {
    role=syncopeRoleDAO.find(roleId);
  }
  if (role == null) {
    LOG.error("String_Node_Str" + roleId + "String_Node_Str");
    SyncopeClientCompositeErrorException compositeErrorException=new SyncopeClientCompositeErrorException(HttpStatus.BAD_REQUEST);
    SyncopeClientException ex=new SyncopeClientException(SyncopeClientExceptionType.RequiredValuesMissing);
    ex.addElement("String_Node_Str");
    compositeErrorException.addException(ex);
    throw compositeErrorException;
  }
  List<SchemaMappingTO> roleMappings=new ArrayList<SchemaMappingTO>();
  Set<TargetResource> resources=role.getTargetResources();
  List<SchemaMappingTO> resourceMappings=null;
  for (  TargetResource resource : resources) {
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str");
    }
    List<SchemaMapping> schemaMappings=resource.getMappings();
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str"+ schemaMappings+ "String_Node_Str");
    }
    resourceMappings=binder.getSchemaMappingTOs(schemaMappings);
    if (LOG.isDebugEnabled()) {
      LOG.debug("String_Node_Str" + resource + "String_Node_Str"+ resourceMappings+ "String_Node_Str");
    }
    roleMappings.addAll(resourceMappings);
  }
  LOG.debug("String_Node_Str",roleMappings);
  return roleMappings;
}