From: Nikos Mavrogiannopoulos Date: Sat, 10 Sep 2011 19:49:08 +0000 (+0200) Subject: documentation update X-Git-Tag: gnutls_3_0_3~15 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6bae4ee84d1590e7a41df3fc0d5278f865e2c163;p=thirdparty%2Fgnutls.git documentation update --- diff --git a/doc/cha-gtls-app.texi b/doc/cha-gtls-app.texi index 5ccb159082..5f097f4f1e 100644 --- a/doc/cha-gtls-app.texi +++ b/doc/cha-gtls-app.texi @@ -207,12 +207,16 @@ for more information). Once the handshake is complete and peer's identity has been verified data can be exchanged. The available functions resemble the POSIX @code{recv} and @code{send} -functions. +functions. It is suggested to use @funcref{gnutls_error_is_fatal} +to check whether the error codes returned by these functions are +fatal for the protocol or can be ignored. @showfuncdesc{gnutls_record_send} @showfuncdesc{gnutls_record_recv} +@showfuncdesc{gnutls_error_is_fatal} + In DTLS it is adviceable to use the extended receive function shown below, because it allows the extraction of the sequence number. This is required in DTLS because diff --git a/lib/gnutls_errors.c b/lib/gnutls_errors.c index 30d1af7a33..cfb3433d0c 100644 --- a/lib/gnutls_errors.c +++ b/lib/gnutls_errors.c @@ -341,10 +341,10 @@ static const gnutls_error_entry error_algorithms[] = { * @error: is a GnuTLS error code, a negative error code * * If a GnuTLS function returns a negative error code you may feed that - * value to this function to see if the error condition is fatal. - * - * Note that you may want to check the error code manually, since some - * non-fatal errors to the protocol may be fatal for you program. + * value to this function to see if the error condition is fatal. + * Note that you may also want to check the error code manually, since some + * non-fatal errors to the protocol (such as a warning alert or + * a rehandshake request) may be fatal for your program. * * This function is only useful if you are dealing with errors from * the record layer or the handshake layer.