Fixed docshell test bug default tip
authorRiccardo Pelizzi <r.pelizzi@gmail.com>
Sat, 11 Aug 2012 14:33:31 -0400
changeset 50 f1e86f56ee2795aa0596a442eef3d8a8dd7ff4a5
parent 49 244c359a659a0af8305c13bb711e0f27065f12a0
push id30
push userr.pelizzi@gmail.com
push dateSat, 11 Aug 2012 18:33:35 +0000
Fixed docshell test bug
series
xssfilter
--- a/series
+++ b/series
@@ -1,4 +1,4 @@
 xssfilter
+tryserver
 tryserver-all
-tryserver
 csp-filter
--- a/xssfilter
+++ b/xssfilter
@@ -4816,18 +4816,18 @@ diff --git a/docshell/test/navigation/na
      <script src="NavigationUtils.js"></script>
      <script>
 +
 +    function setXss(value) {        
 +        netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
 +        var prefService = Components.classes["@mozilla.org/preferences-service;1"]
 +	  .getService(Components.interfaces.nsIPrefService);
 +        var xssBranch = prefService.getBranch("security.xssfilter.");
-+        originalValue = xssBranch.getBoolPref("enabled");
-+        xssBranch.setBoolPref("enabled", value);
++        originalValue = xssBranch.getBoolPref("enable");
++        xssBranch.setBoolPref("enable", value);
 +    }
 +
      function navigate() {
 +        // some tests using this page will trigger an xss violation
 +        setXss(false);
 +
          var arguments = window.location.hash.substring(1).split(",");
          var target = arguments[0];