[Pkg-mozext-commits] [perspectives-extension] 53/72: Pers_statusbar - Update nsIX509Cert and nsIX509CertDB calls for Firefox 33

David Prévot taffit at moszumanska.debian.org
Thu Dec 11 02:12:50 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository perspectives-extension.

commit fbee688e7699cae143adbcfcac10710771e6b11a
Author: Dave Schaefer <dave.schaefer at gmail.com>
Date:   Thu Oct 23 22:26:19 2014 -0600

    Pers_statusbar - Update nsIX509Cert and nsIX509CertDB calls for Firefox 33
    
    The old interfaces that used numbers have been merged into
    the main interfaces.
    
    https://developer.mozilla.org/en-US/Firefox/Releases/33
    https://bugzilla.mozilla.org/show_bug.cgi?id=643041
---
 plugin/chrome/content/statusbar.js | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/plugin/chrome/content/statusbar.js b/plugin/chrome/content/statusbar.js
index 0ffbaf3..2086cfd 100644
--- a/plugin/chrome/content/statusbar.js
+++ b/plugin/chrome/content/statusbar.js
@@ -140,14 +140,16 @@ var Pers_statusbar = {
 
 				var nCerts      = 0;
 				var nDistrusted = 0;
-				var certDB2 = Cc["@mozilla.org/security/x509certdb;1"].getService(Ci.nsIX509CertDB2);
+				// nsIX509CertDB2 functionality moved to nsIX509CertDB in Firefox 33
+				var certDB2 = Cc["@mozilla.org/security/x509certdb;1"].getService(Ci.nsIX509CertDB || Ci.nsIX509CertDB2);
 				certDB2.QueryInterface(Ci.nsIX509CertDB);
 				var it = certDB2.getCerts().getEnumerator();
 				while(it.hasMoreElements())
 				{
 					var cert = it.getNext();
 
-					cert.QueryInterface(Ci.nsIX509Cert2);
+					// nsIX509Cert2 functionality moved to nsIX509Cert in Firefox 33
+					cert.QueryInterface(Ci.nsIX509Cert || Ci.nsIX509Cert2);
 					var trustSSL     = certDB2.isCertTrusted(cert, cert.certType, Ci.nsIX509CertDB.TRUSTED_SSL    );
 					var trustEmail   = certDB2.isCertTrusted(cert, cert.certType, Ci.nsIX509CertDB.TRUSTED_EMAIL  );
 					var trustObjsign = certDB2.isCertTrusted(cert, cert.certType, Ci.nsIX509CertDB.TRUSTED_OBJSIGN);

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-mozext/perspectives-extension.git



More information about the Pkg-mozext-commits mailing list