- certstat = gnutls_certificate_verify_peers (state);
-
- if (certstat == GNUTLS_E_NO_CERTIFICATE_FOUND) {
- mutt_error (_("Unable to get certificate from peer"));
- mutt_sleep (2);
- return 0;
- }
- if (certstat < 0) {
- mutt_error (_("Certificate verification error (%s)"),
- gnutls_strerror (certstat));
- mutt_sleep (2);
- return 0;
+ if (gnutls_certificate_verify_peers2(state, &certstat) < 0) {
+ mutt_error (_("Certificate verification error (%s)"),
+ gnutls_strerror(certstat));
+ mutt_sleep (2);
+ return 0;