1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2025-12-29 00:31:01 -08:00

Build fix for older gnutls versions

* src/gnutls.c (emacs_gnutls_handle_error):
GNUTLS_E_PREMATURE_TERMINATION is apparently only present in
gnutls-3.
This commit is contained in:
Lars Ingebrigtsen 2017-01-25 14:21:13 +01:00
parent cf9ce4fcfc
commit 6bfa9e9abc

View file

@ -586,8 +586,10 @@ emacs_gnutls_handle_error (gnutls_session_t session, int err)
/* Mostly ignore "The TLS connection was non-properly
terminated" message which just means that the peer closed the
connection. */
#ifdef HAVE_GNUTLS3
if (err == GNUTLS_E_PREMATURE_TERMINATION)
level = 3;
#endif
GNUTLS_LOG2 (level, max_log_level, "fatal error:", str);
ret = 0;