summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2014-05-04 12:50:06 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2014-05-04 12:50:06 +0200
commitb15bb9334326b6d4076c610843f30eb9c8251e7b (patch)
treeec61e6d53b8f30743d598a8c6e1630ea97e551d1
parentca6d84445e162d440c0eb7a42d2e7427172cff64 (diff)
downloadgnutls-b15bb9334326b6d4076c610843f30eb9c8251e7b.tar.gz
initialize to null the SRP extension data on allocation.
Issue identified using valgrind and the Codenomicon TLS test suite.
-rw-r--r--lib/ext/srp.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/ext/srp.c b/lib/ext/srp.c
index 403abd8d72..13eb27567c 100644
--- a/lib/ext/srp.c
+++ b/lib/ext/srp.c
@@ -129,7 +129,7 @@ _gnutls_srp_send_params (gnutls_session_t session,
if (cred == NULL)
return 0;
- priv = gnutls_malloc (sizeof (*priv));
+ priv = gnutls_calloc (1, sizeof (*priv));
if (priv == NULL)
return gnutls_assert_val(GNUTLS_E_MEMORY_ERROR);