From 29ad7e8fc07822b0d513c028b3c274590a924556 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Manuel=20P=C3=A9gouri=C3=A9-Gonnard?= Date: Wed, 23 Jul 2014 19:12:15 +0200 Subject: [PATCH] Add check for missing ssl_set_client_transport_id() --- library/ssl_cookie.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/library/ssl_cookie.c b/library/ssl_cookie.c index 86cdc12ac..b2bb9cd0c 100644 --- a/library/ssl_cookie.c +++ b/library/ssl_cookie.c @@ -114,7 +114,7 @@ int ssl_cookie_write( void *p_ctx, unsigned char hmac_out[HVR_MD_LEN]; ssl_cookie_ctx *ctx = (ssl_cookie_ctx *) p_ctx; - if( ctx == NULL ) + if( ctx == NULL || cli_id == NULL ) return( POLARSSL_ERR_SSL_BAD_INPUT_DATA ); if( (size_t)( end - *p ) < HVR_MD_USE )