Program: 63024
Project: 63024
Buggy source:
public static RepositoryResult<Statement> getPropertyStatementsSparql(RepositoryConnection conn,Resource subj,IRI pred,Value obj,int aLimit,boolean includeInferred,String language) throws QueryEvaluationException {
  String filter="String_Node_Str";
  if (language != null) {
    filter="String_Node_Str" + NTriplesUtil.escapeString(language) + "String_Node_Str";
  }
  String QUERY=String.join("String_Node_Str",InferencerVariableStore.PREFIX_OWL,InferencerVariableStore.PREFIX_RDF,InferencerVariableStore.PREFIX_RDFS,"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",filter,"String_Node_Str");
  TupleQuery tupleQuery=conn.prepareTupleQuery(QueryLanguage.SPARQL,QUERY);
  if (subj != null) {
    tupleQuery.setBinding("String_Node_Str",subj);
  }
  if (pred != null) {
    tupleQuery.setBinding("String_Node_Str",pred);
  }
  if (obj != null) {
    tupleQuery.setBinding("String_Node_Str",obj);
  }
  tupleQuery.setIncludeInferred(includeInferred);
  TupleQueryResult result=tupleQuery.evaluate();
  Iteration<Statement,QueryEvaluationException> i1=new ConvertingIteration<BindingSet,Statement,QueryEvaluationException>(result){
    @Override protected Statement convert(    BindingSet b) throws QueryEvaluationException {
      Resource s=subj == null ? (Resource)b.getValue("String_Node_Str") : subj;
      IRI p=pred == null ? (IRI)b.getValue("String_Node_Str") : pred;
      Value o=obj == null ? b.getValue("String_Node_Str") : obj;
      return SimpleValueFactory.getInstance().createStatement(s,p,o);
    }
  }
;
  ExceptionConvertingIteration<Statement,RepositoryException> i2=new ExceptionConvertingIteration<Statement,RepositoryException>(i1){
    @Override protected RepositoryException convert(    Exception aE){
      return new RepositoryException(aE);
    }
  }
;
  return new RepositoryResult<Statement>(i2);
}

Fixed version (ground truth):
public static RepositoryResult<Statement> getPropertyStatementsSparql(RepositoryConnection conn,Resource subj,IRI pred,Value obj,int aLimit,boolean includeInferred,String language) throws QueryEvaluationException {
  String filter="String_Node_Str";
  if (language != null) {
    filter="String_Node_Str" + NTriplesUtil.escapeString(language) + "String_Node_Str";
  }
  String QUERY=String.join("String_Node_Str","String_Node_Str" + RDFS.NAMESPACE + "String_Node_Str","String_Node_Str" + OWL.NAMESPACE + "String_Node_Str","String_Node_Str" + RDF.NAMESPACE + "String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str",filter,"String_Node_Str");
  TupleQuery tupleQuery=conn.prepareTupleQuery(QueryLanguage.SPARQL,QUERY);
  if (subj != null) {
    tupleQuery.setBinding("String_Node_Str",subj);
  }
  if (pred != null) {
    tupleQuery.setBinding("String_Node_Str",pred);
  }
  if (obj != null) {
    tupleQuery.setBinding("String_Node_Str",obj);
  }
  tupleQuery.setIncludeInferred(includeInferred);
  TupleQueryResult result=tupleQuery.evaluate();
  Iteration<Statement,QueryEvaluationException> i1=new ConvertingIteration<BindingSet,Statement,QueryEvaluationException>(result){
    @Override protected Statement convert(    BindingSet b) throws QueryEvaluationException {
      Resource s=subj == null ? (Resource)b.getValue("String_Node_Str") : subj;
      IRI p=pred == null ? (IRI)b.getValue("String_Node_Str") : pred;
      Value o=obj == null ? b.getValue("String_Node_Str") : obj;
      return SimpleValueFactory.getInstance().createStatement(s,p,o);
    }
  }
;
  ExceptionConvertingIteration<Statement,RepositoryException> i2=new ExceptionConvertingIteration<Statement,RepositoryException>(i1){
    @Override protected RepositoryException convert(    Exception aE){
      return new RepositoryException(aE);
    }
  }
;
  return new RepositoryResult<Statement>(i2);
}