Fixed a Qt5 related issue in the SSL certificate info widget.

Sat, 13 Apr 2013 18:47:11 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Sat, 13 Apr 2013 18:47:11 +0200
changeset 2578
f181c1420148
parent 2577
14296525eff5
child 2579
35bb8c5eb7fe

Fixed a Qt5 related issue in the SSL certificate info widget.

E5Network/E5SslCertificatesInfoWidget.py file | annotate | diff | comparison | revisions
--- a/E5Network/E5SslCertificatesInfoWidget.py	Sat Apr 13 15:25:07 2013 +0200
+++ b/E5Network/E5SslCertificatesInfoWidget.py	Sat Apr 13 18:47:11 2013 +0200
@@ -44,9 +44,15 @@
         self.__chain = certificateChain[:]
         
         for cert in self.__chain:
-            name = cert.subjectInfo(QSslCertificate.CommonName)
+            if qVersion() >= "5.0.0":
+                name = ", ".join(cert.subjectInfo(QSslCertificate.CommonName))
+            else:
+                name = cert.subjectInfo(QSslCertificate.CommonName)
             if not name:
-                name = cert.subjectInfo(QSslCertificate.Organization)
+                if qVersion() >= "5.0.0":
+                    name = ", ".join(cert.subjectInfo(QSslCertificate.Organization))
+                else:
+                    name = cert.subjectInfo(QSslCertificate.Organization)
             if not name:
                 name = cert.serialNumber()
             self.chainComboBox.addItem(name)

eric ide

mercurial