[ 
https://issues.apache.org/jira/browse/JENA-1382?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Andy Seaborne resolved JENA-1382.
---------------------------------
       Resolution: Fixed
         Assignee: Andy Seaborne
    Fix Version/s: Jena 3.5.0

> NPE in ResultSetClosable
> ------------------------
>
>                 Key: JENA-1382
>                 URL: https://issues.apache.org/jira/browse/JENA-1382
>             Project: Apache Jena
>          Issue Type: Bug
>          Components: ARQ
>    Affects Versions: Jena 3.2.0, Jena 3.3.0, Jena 3.4.0
>            Reporter: Lorenz Bühmann
>            Assignee: Andy Seaborne
>            Priority: Minor
>             Fix For: Jena 3.5.0
>
>
> Using {{ResultSetClosable}} leads to a NPE for {{QueryExecution}} objects 
> that have been created based on the query string only, i.e. without a parsed 
> {{Query}} object because of the [sanity 
> check|https://github.com/apache/jena/blob/master/jena-arq/src/main/java/org/apache/jena/query/ResultSetCloseable.java#L38]
>  regarding {{SELECT}} queries. 
> Example:
> {code:java}
> QueryEngineHttp qe = new QueryEngineHttp("http://dbpedia.org/sparql";, "select 
> * { ?s ?p ?o } limit 1");
> try(ResultSetCloseable rs = ResultSetCloseable.closableResultSet(qe)) {
>   rs.hasNext();
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to