diff --git a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java index f5eab8310f7ffc3182cc80eae7146c33a9fe3bd7..5910482bffce5cb31307738c7cb092ae6312d8a9 100644 --- a/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java +++ b/src/interfaces/jdbc/org/postgresql/largeobject/LargeObject.java @@ -92,7 +92,12 @@ public class LargeObject /* Release large object resources during garbage cleanup */ protected void finalize() throws SQLException { - close(); + //This code used to call close() however that was problematic + //because the scope of the fd is a transaction, thus if commit + //or rollback was called before garbage collection ran then + //the call to close would error out with an invalid large object + //handle. So this method now does nothing and lets the server + //handle cleanup when it ends the transaction. } /*