ozeigermann 2004/11/10 14:09:13
Modified: src/stores/org/apache/slide/store/impl/rdbms Tag:
SLIDE_2_1_RELEASE_BRANCH StandardRDBMSAdapter.java
Log:
Reversed the sequence of closing statement and connection to avoid error
with temporary connections
Revision Changes Path
No revision
No revision
1.32.2.3 +10 -10
jakarta-slide/src/stores/org/apache/slide/store/impl/rdbms/StandardRDBMSAdapter.java
Index: StandardRDBMSAdapter.java
===================================================================
RCS file:
/home/cvs/jakarta-slide/src/stores/org/apache/slide/store/impl/rdbms/StandardRDBMSAdapter.java,v
retrieving revision 1.32.2.2
retrieving revision 1.32.2.3
diff -u -r1.32.2.2 -r1.32.2.3
--- StandardRDBMSAdapter.java 5 Oct 2004 20:56:10 -0000 1.32.2.2
+++ StandardRDBMSAdapter.java 10 Nov 2004 22:09:12 -0000 1.32.2.3
@@ -754,10 +754,12 @@
}
}
} finally {
- // do not close when not compressed, as stream needs to be
read
- // before
- if (bcompress) {
- try {
+ try {
+ close(statement, res);
+ } finally {
+ // do not close when not compressed, as stream needs to
be read
+ // before
+ if (bcompress) {
if (temporaryConnection) {
// XXX is needed, as calling store does not know
if
// connection should be closed now
@@ -767,8 +769,6 @@
connection.close();
}
}
- } finally {
- close(statement, res);
}
}
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]