From a9d562064aa4d8bfcbfa897eddab7c5895dee5fc Mon Sep 17 00:00:00 2001 From: Nikos Mavrogiannopoulos Date: Tue, 31 Mar 2015 13:37:43 +0200 Subject: [PATCH] tlslib: define DTLS1_2 when needed --- src/tlslib.c | 3 --- src/tlslib.h | 4 ++++ 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/tlslib.c b/src/tlslib.c index 89f518a5..1aabd9fe 100644 --- a/src/tlslib.c +++ b/src/tlslib.c @@ -834,9 +834,6 @@ size_t tls_get_overhead(gnutls_protocol_t version, gnutls_cipher_algorithm_t cip #if GNUTLS_VERSION_NUMBER >= 0x030207 return gnutls_est_record_overhead_size(version, cipher, mac, GNUTLS_COMP_NULL, 0); #else -# if GNUTLS_VERSION_NUMBER < 0x030200 -# define GNUTLS_DTLS1_2 202 -# endif unsigned overhead = 0, t; unsigned block_size; block_size = gnutls_cipher_get_block_size(cipher); diff --git a/src/tlslib.h b/src/tlslib.h index 7fc71aff..8c20150e 100644 --- a/src/tlslib.h +++ b/src/tlslib.h @@ -27,6 +27,10 @@ #include #include +# if GNUTLS_VERSION_NUMBER < 0x030200 +# define GNUTLS_DTLS1_2 202 +# endif + typedef struct { struct htable *ht;