After closing a DataSet, an attempt to close the associated Query object throws a NPE, even though the isClosed() method of the Query object returns false. The attached test case produces the following output: Dropping table... Creating table... Closing DataSet addressesDS. Is addressesDS closed? true Is Query object aq closed? false Closing Query object aq. Exception in thread "main" java.sql.SQLRuntimeException: java.lang.NullPointerException at com.sun.sql.QueryObjectGeneratorImpl.deregisterAllDataSets(Unknown Source) at com.sun.sql.QueryObjectGeneratorImpl.invoke(Unknown Source) at $Proxy0.close(Unknown Source) at CloseTest.main(CloseTest.java:67) Caused by: java.lang.NullPointerException at com.sun.sql.DataSetImpl$DataSetItr.<init>(Unknown Source) at com.sun.sql.DataSetImpl.iterator(Unknown Source) at java.util.AbstractList.hashCode(AbstractList.java:524) at java.util.WeakHashMap.remove(WeakHashMap.java:543) at java.util.WeakHashMap$HashIterator.remove(WeakHashMap.java:779) ... 4 more
|