[glib-networking/tls-database] gnutls: Fix a couple bugs in GTlsDatabaseGnutls::verify_chain()
- From: Stefan Walter <stefw src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glib-networking/tls-database] gnutls: Fix a couple bugs in GTlsDatabaseGnutls::verify_chain()
- Date: Tue, 28 Dec 2010 16:32:37 +0000 (UTC)
commit 17490a4bd7d1d33548c1884155e26cbbd4006d55
Author: Stef Walter <stefw collabora co uk>
Date: Tue Dec 28 10:30:31 2010 -0600
gnutls: Fix a couple bugs in GTlsDatabaseGnutls::verify_chain()
* Initialize anchor correctly.
* Check correctly for lookup errors.
tls/gnutls/gtlsdatabase-gnutls.c | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/tls/gnutls/gtlsdatabase-gnutls.c b/tls/gnutls/gtlsdatabase-gnutls.c
index b8c1248..6c3a642 100644
--- a/tls/gnutls/gtlsdatabase-gnutls.c
+++ b/tls/gnutls/gtlsdatabase-gnutls.c
@@ -135,9 +135,10 @@ build_certificate_chain (GTlsDatabaseGnutls *self,
purpose, identity, cancellable, error))
{
g_tls_certificate_gnutls_set_issuer (certificate, NULL);
+ *anchor = certificate;
return STATUS_ANCHORED;
}
- else if (error)
+ else if (*error)
{
return STATUS_FAILURE;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]