Bug 711494 - close _dbConnection. r=mak.
authorRafael Ávila de Espíndola <respindola@mozilla.com>
Mon, 19 Dec 2011 13:10:18 -0500
changeset 84688 6e57fcb02e687aca62247c66986e481ade69325e
parent 84687 4c22853f71ce893bf44d29f0bf63af7159856128
child 84689 a3bade82ac92e28f49245a63f27ddafbb6c1dd6c
push id519
push userakeybl@mozilla.com
push dateWed, 01 Feb 2012 00:38:35 +0000
treeherdermozilla-beta@788ea1ef610b [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmak
bugs711494
milestone11.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 711494 - close _dbConnection. r=mak.
toolkit/components/contentprefs/nsContentPrefService.js
--- a/toolkit/components/contentprefs/nsContentPrefService.js
+++ b/toolkit/components/contentprefs/nsContentPrefService.js
@@ -299,16 +299,18 @@ ContentPrefService.prototype = {
       this.__stmtDeletePref.finalize();
       this.__stmtDeletePref = null;
     }
     if (this.__stmtUpdatePref) {
       this.__stmtUpdatePref.finalize();
       this.__stmtUpdatePref = null;
     }
 
+    this._dbConnection.asyncClose();
+
     // Delete references to XPCOM components to make sure we don't leak them
     // (although we haven't observed leakage in tests).  Also delete references
     // in _observers and _genericObservers to avoid cycles with those that
     // refer to us and don't remove themselves from those observer pools.
     for (var i in this) {
       try { this[i] = null }
       // Ignore "setting a property that has only a getter" exceptions.
       catch(ex) {}