Curl_cpool_init(&multi->cpool, multi->admin, NULL, chashsize);
+#ifdef USE_SSL
if(Curl_ssl_scache_create(sesssize, 2, &multi->ssl_scache))
goto error;
+#else
+ (void)sesssize;
+#endif
#ifdef USE_WINSOCK
multi->wsa_event = WSACreateEvent();
if(multi->wsa_event == WSA_INVALID_EVENT)
goto error;
-#else
-#ifdef ENABLE_WAKEUP
+#elif defined(ENABLE_WAKEUP)
if(wakeup_create(multi->wakeup_pair, TRUE) < 0) {
multi->wakeup_pair[0] = CURL_SOCKET_BAD;
multi->wakeup_pair[1] = CURL_SOCKET_BAD;
}
-#endif
#endif
return multi;
Curl_dnscache_destroy(&multi->dnscache);
Curl_cpool_destroy(&multi->cpool);
Curl_cshutdn_destroy(&multi->cshutdn, multi->admin);
+#ifdef USE_SSL
Curl_ssl_scache_destroy(multi->ssl_scache);
+#endif
if(multi->admin) {
multi->admin->multi = NULL;
Curl_close(&multi->admin);
Curl_hash_destroy(&multi->proto_hash);
Curl_dnscache_destroy(&multi->dnscache);
Curl_psl_destroy(&multi->psl);
+#ifdef USE_SSL
Curl_ssl_scache_destroy(multi->ssl_scache);
+#endif
#ifdef USE_WINSOCK
WSACloseEvent(multi->wsa_event);
void *userptr);
#endif /* USE_SSLS_EXPORT */
-
-#else /* USE_SSL */
-
-#define Curl_ssl_scache_create(x,y,z) ((void)x, CURLE_OK)
-#define Curl_ssl_scache_destroy(x) do {} while(0)
-
-#endif /* USE_SSL (else) */
+#endif /* USE_SSL */
#endif /* HEADER_CURL_VTLS_SCACHE_H */