From: Nikos Mavrogiannopoulos Date: Mon, 29 Jul 2013 21:51:51 +0000 (+0200) Subject: allow empty fragments with padding. X-Git-Tag: gnutls_3_2_3~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fa908a83fd0a90f9a482a1d4f4ae096d7d6a7fb2;p=thirdparty%2Fgnutls.git allow empty fragments with padding. --- diff --git a/lib/gnutls_record.c b/lib/gnutls_record.c index ffe5f4681a..537a0d7dd0 100644 --- a/lib/gnutls_record.c +++ b/lib/gnutls_record.c @@ -501,7 +501,7 @@ _gnutls_send_tlen_int (gnutls_session_t session, content_type_t type, } else { - if (unlikely(send_data_size == 0)) + if (unlikely((send_data_size == 0 && target_length == 0))) return gnutls_assert_val(GNUTLS_E_INTERNAL_ERROR); /* now proceed to packet encryption