]> source.dussan.org Git - tigervnc.git/commitdiff
System certificate load returns number loaded not GNUTLS_E_SUCCESS 1347/head
authorTyson Whitehead <twhitehead@gmail.com>
Fri, 1 Oct 2021 22:35:19 +0000 (18:35 -0400)
committerTyson Whitehead <twhitehead@gmail.com>
Thu, 7 Oct 2021 14:19:12 +0000 (10:19 -0400)
common/rfb/CSecurityTLS.cxx

index df4b37b57abaca8fc12ab94ce68438df6b37e37e..be70c55939967fe658d8c4da0bbe6db0722c8411 100644 (file)
@@ -284,7 +284,7 @@ void CSecurityTLS::setParam()
     if (gnutls_certificate_allocate_credentials(&cert_cred) != GNUTLS_E_SUCCESS)
       throw AuthFailureException("gnutls_certificate_allocate_credentials failed");
 
-    if (gnutls_certificate_set_x509_system_trust(cert_cred) != GNUTLS_E_SUCCESS)
+    if (gnutls_certificate_set_x509_system_trust(cert_cred) < 1)
       vlog.error("Could not load system certificate trust store");
 
     if (*cafile && gnutls_certificate_set_x509_trust_file(cert_cred,cafile,GNUTLS_X509_FMT_PEM) < 0)