Fix memory leak if SSL session id is not present

This commit is contained in:
William Robinet 2015-04-22 11:32:42 +02:00
parent 4310c3f117
commit 3ca46766e4

View file

@ -260,8 +260,9 @@ int ssl_set_client_session_id(d,msg,len)
#ifdef OPENSSL #ifdef OPENSSL
int r; int r;
if(r=r_data_create(&d->session_id,msg,len)) if(len>0)
ERETURN(r); if(r=r_data_create(&d->session_id,msg,len))
ERETURN(r);
#endif #endif
return(0); return(0);
} }