From: Michael Catanzaro Date: Fri, 9 Feb 2018 16:22:24 +0000 (-0600) Subject: Improve documentation of gnutls_x509_trust_list_iter_get_ca [ci skip] X-Git-Tag: gnutls_3_6_2~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=48db5be4957df94551fda2fab96847742e500dc7;p=thirdparty%2Fgnutls.git Improve documentation of gnutls_x509_trust_list_iter_get_ca [ci skip] The documentation is confusing because it implies that gnutls_x509_trust_list_iter_deinit() should be called after using this function, but in fact it is generally not necessary. Also, there was a typo here ("usin"). Signed-off-by: Michael Catanzaro --- diff --git a/lib/x509/verify-high.c b/lib/x509/verify-high.c index 7b375d61fb..18906ddc1a 100644 --- a/lib/x509/verify-high.c +++ b/lib/x509/verify-high.c @@ -397,8 +397,11 @@ advance_iter(gnutls_x509_trust_list_t list, * When past the last element is accessed %GNUTLS_E_REQUESTED_DATA_NOT_AVAILABLE * is returned and the iterator is reset. * - * After use, the iterator must be deinitialized usin - * gnutls_x509_trust_list_iter_deinit(). + * The iterator is deinitialized and reset to %NULL automatically by this + * function after iterating through all elements until + * %GNUTLS_E_REQUESTED_DATA_NOT_AVAILABLE is returned. If the iteration is + * aborted early, it must be manually deinitialized using + * gnutls_x509_trust_list_iter_deinit(). * * Returns: On success, %GNUTLS_E_SUCCESS (0) is returned, otherwise a * negative error value.