diff options
-rw-r--r-- | lib/gnutls_compress.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/lib/gnutls_compress.c b/lib/gnutls_compress.c index 727de98db8..6ceafbbc21 100644 --- a/lib/gnutls_compress.c +++ b/lib/gnutls_compress.c @@ -205,13 +205,20 @@ _gnutls_supported_compression_methods (gnutls_session_t session, uint8_t * comp, size_t comp_size) { unsigned int i, j; + int tmp; if (comp_size < SUPPORTED_COMPRESSION_METHODS) return gnutls_assert_val(GNUTLS_E_INTERNAL_ERROR); for (i = j = 0; i < SUPPORTED_COMPRESSION_METHODS; i++) { - int tmp = + if (IS_DTLS(session) && session->internals.priorities.compression.priority[i] != GNUTLS_COMP_NULL) + { + gnutls_assert(); + continue; + } + + tmp = _gnutls_compression_get_num (session->internals. priorities.compression.priority[i]); |