Don't try to restore auto-commit on a closed connection.

git-svn-id: https://samskivert.googlecode.com/svn/trunk@2149 6335cc39-0255-0410-8fd6-9bcaacd3b74c
This commit is contained in:
mdb
2007-07-30 22:08:20 +00:00
parent 2b80f75546
commit fc29a71f3f
@@ -245,7 +245,7 @@ public class SimpleRepository extends Repository
} finally {
if (conn != null) {
// restore our auto-commit settings
if (oldAutoCommit != null) {
if (oldAutoCommit != null && !conn.isClosed()) {
try {
conn.setAutoCommit(oldAutoCommit);
} catch (SQLException sace) {