Browse files

Restore enablePrivilege hack for non-browser-chrome consumers in mock…

…Objects.js
  • Loading branch information...
1 parent 1dbe9d6 commit 90e0beaf126741577fcb51ffd76b83066c1fac0d Dão Gottwald committed Jul 20, 2011
Showing with 2 additions and 0 deletions.
  1. +2 −0 toolkit/content/tests/browser/common/mockObjects.js
View
2 toolkit/content/tests/browser/common/mockObjects.js
@@ -65,6 +65,7 @@ MockObjectRegisterer.prototype = {
* to ensure that unregister() is called.
*/
register: function MOR_register() {
+ netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
if (this._originalCID)
throw new Exception("Invalid object state when calling register()");
@@ -96,6 +97,7 @@ MockObjectRegisterer.prototype = {
* Restores the original factory.
*/
unregister: function MOR_unregister() {
+ netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
if (!this._originalCID)
throw new Exception("Invalid object state when calling unregister()");

0 comments on commit 90e0bea

Please sign in to comment.