Skip to content

Commit

Permalink
[CONJ-403] NPE when result-set close() after having thrown an exception
Browse files Browse the repository at this point in the history
  • Loading branch information
rusher committed Jan 3, 2017
1 parent 73657f8 commit 628cd85
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,7 @@ public boolean readNextValue(List<byte[][]> values) throws IOException, QueryExc
ErrorPacket errorPacket = new ErrorPacket(buffer, false);
lastReusableArray = null;
protocol = null;
isEof = true;
packetFetcher = null;
inputStream = null;
if (statement != null) {
Expand Down Expand Up @@ -446,6 +447,7 @@ public boolean readNextValue(List<byte[][]> values) throws IOException, QueryExc
ErrorPacket errorPacket = new ErrorPacket(buffer);
lastReusableArray = null;
protocol = null;
isEof = true;
packetFetcher = null;
inputStream = null;
if (statement != null) {
Expand Down Expand Up @@ -514,6 +516,7 @@ public void close() throws SQLException {
ExceptionMapper.throwException(queryException, null, this.statement);
} finally {
protocol = null;
isEof = true;
packetFetcher = null;
inputStream = null;
lock.unlock();
Expand Down

0 comments on commit 628cd85

Please sign in to comment.