From: Nikos Mavrogiannopoulos Date: Thu, 2 Jun 2011 22:44:05 +0000 (+0200) Subject: updated X-Git-Tag: gnutls_2_99_3~63 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c192c6fbf31ae1db05155a8e1b6029c241303938;p=thirdparty%2Fgnutls.git updated --- diff --git a/lib/ext/ecc.c b/lib/ext/ecc.c index f6d0218f68..358b3ea1f9 100644 --- a/lib/ext/ecc.c +++ b/lib/ext/ecc.c @@ -1,6 +1,5 @@ /* - * Copyright (C) 2002, 2003, 2004, 2005, 2010 Free Software Foundation, - * Inc. + * Copyright (C) 2011 Free Software Foundation, Inc. * * Author: Nikos Mavrogiannopoulos * @@ -215,8 +214,8 @@ int data_size = _data_size; len = data[0]; DECR_LEN (data_size, len+1); - for (i=0;isecurity_parameters.entity == GNUTLS_SERVER && !_gnutls_session_is_ecc(session)) return 0; - /* this extension is only being sent on client and server side */ - _gnutls_buffer_append_data(extdata, p, 2); - return 2; + if (session->internals.priorities.supported_ecc.algorithms > 0) + { + _gnutls_buffer_append_data(extdata, p, 2); + return 2; + } + return 0; }