[FFmpeg-devel] [PATCH 1/2] lavf/tls_gnutls: fix compilation with GnuTLS 2.x
Moritz Barsnick
barsnick at gmx.net
Tue Sep 26 14:25:53 EEST 2017
Commit 598e41684066feba701d19ca7443d24b9e5efa77 added use of
GNUTLS_E_PREMATURE_TERMINATION, which wasn't introduced to GnuTLS
before 2.99.x / 3.x. This fixes compilation with older versions.
Signed-off-by: Moritz Barsnick <barsnick at gmx.net>
---
libavformat/tls_gnutls.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/libavformat/tls_gnutls.c b/libavformat/tls_gnutls.c
index 38f8ea4..7174dfd 100644
--- a/libavformat/tls_gnutls.c
+++ b/libavformat/tls_gnutls.c
@@ -72,7 +72,9 @@ static int print_tls_error(URLContext *h, int ret)
switch (ret) {
case GNUTLS_E_AGAIN:
case GNUTLS_E_INTERRUPTED:
+#ifdef GNUTLS_E_PREMATURE_TERMINATION
case GNUTLS_E_PREMATURE_TERMINATION:
+#endif
break;
case GNUTLS_E_WARNING_ALERT_RECEIVED:
av_log(h, AV_LOG_WARNING, "%s\n", gnutls_strerror(ret));
--
2.9.5
More information about the ffmpeg-devel
mailing list