Skip to content
Snippets Groups Projects
Commit 2179e6e7 authored by Daniel Stenberg's avatar Daniel Stenberg
Browse files

prevent memory leak when built SSL disabled

parent 7dde3d18
No related branches found
No related tags found
No related merge requests found
......@@ -499,6 +499,7 @@ int Curl_ssl_recv(struct connectdata *conn, /* connection data */
*/
CURLcode Curl_ssl_initsessions(struct SessionHandle *data, long amount)
{
#ifdef USE_SSL
struct curl_ssl_session *session;
if(data->state.session)
......@@ -517,6 +518,11 @@ CURLcode Curl_ssl_initsessions(struct SessionHandle *data, long amount)
data->set.ssl.numsessions = amount;
data->state.session = session;
data->state.sessionage = 1; /* this is brand new */
#else
/* without SSL, do nothing */
(void)data;
(void)amount;
#endif
return CURLE_OK;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment