From: Nikos Mavrogiannopoulos Date: Tue, 9 Jul 2013 06:39:51 +0000 (+0200) Subject: Include MKI size in size calculations for the extension. X-Git-Tag: gnutls_3_2_2~22 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=48765ad8252e29371e4b3d2be97f2987e106dcc8;p=thirdparty%2Fgnutls.git Include MKI size in size calculations for the extension. This prevents a parsing error when MKI is being used. Reported by Gábor Tatárka. --- diff --git a/lib/ext/srtp.c b/lib/ext/srtp.c index d29b543458..dbc71d9672 100644 --- a/lib/ext/srtp.c +++ b/lib/ext/srtp.c @@ -294,8 +294,9 @@ _gnutls_srtp_send_params (gnutls_session_t session, ret = _gnutls_buffer_append_data_prefix(extdata, 8, priv->mki, priv->mki_size); if (ret < 0) return gnutls_assert_val(ret); + total_size += 1 + priv_mki_size; - return total_size + 1; + return total_size; } /**