From: Nikos Mavrogiannopoulos Date: Wed, 19 Feb 2014 06:39:44 +0000 (+0100) Subject: Corrected check for present constraints in unsupported types. X-Git-Tag: gnutls_3_3_0pre0~155 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=036bd765a4db40dd01cdd97140ce9b7ea55575aa;p=thirdparty%2Fgnutls.git Corrected check for present constraints in unsupported types. --- diff --git a/lib/x509/name_constraints.c b/lib/x509/name_constraints.c index e9763db772..dd07e6fe9d 100644 --- a/lib/x509/name_constraints.c +++ b/lib/x509/name_constraints.c @@ -507,10 +507,12 @@ gnutls_datum_t rname; i = 0; do { ret = gnutls_x509_name_constraints_get_excluded(nc, i++, &rtype, &rname); - if (ret >= 0 && rtype != type) - continue; - - return gnutls_assert_val(0); + if (ret >= 0) { + if (rtype != type) + continue; + else + return gnutls_assert_val(0); + } } while(ret == 0);