[Zope3-checkins] SVN: Zope3/trunk/src/zope/app/appsetup/ Do not
leak a ZODB connection in IDatabaseOpenedEvent subscriber.
Also fixed
Marius Gedminas
marius at pov.lt
Tue Feb 15 20:11:34 EST 2005
Log message for revision 29154:
Do not leak a ZODB connection in IDatabaseOpenedEvent subscriber. Also fixed
the same leak in tests.
Changed:
U Zope3/trunk/src/zope/app/appsetup/bootstrap.py
U Zope3/trunk/src/zope/app/appsetup/tests.py
-=-
Modified: Zope3/trunk/src/zope/app/appsetup/bootstrap.py
===================================================================
--- Zope3/trunk/src/zope/app/appsetup/bootstrap.py 2005-02-16 01:04:31 UTC (rev 29153)
+++ Zope3/trunk/src/zope/app/appsetup/bootstrap.py 2005-02-16 01:11:34 UTC (rev 29154)
@@ -140,7 +140,8 @@
root_folder.setSiteManager(site_manager)
get_transaction().commit()
- connection.close()
+ connection.close()
+
########################################################################
########################################################################
Modified: Zope3/trunk/src/zope/app/appsetup/tests.py
===================================================================
--- Zope3/trunk/src/zope/app/appsetup/tests.py 2005-02-16 01:04:31 UTC (rev 29153)
+++ Zope3/trunk/src/zope/app/appsetup/tests.py 2005-02-16 01:11:34 UTC (rev 29154)
@@ -109,8 +109,9 @@
self.assert_(IErrorReportingUtility.providedBy(
traverse(package, 'ErrorReporting')))
get_transaction().commit()
- cx.close()
+ cx.close()
+
def test_suite():
suite = unittest.TestSuite()
suite.addTest(unittest.makeSuite(TestBootstrapSubscriber))
More information about the Zope3-Checkins
mailing list