diff options
Diffstat (limited to 'common.c')
-rw-r--r-- | common.c | 15 |
1 files changed, 15 insertions, 0 deletions
@@ -34,6 +34,21 @@ #include <arpa/inet.h> #include <netinet/tcp.h> +static void +init_openssl (void) +{ +#if OPENSSL_VERSION_NUMBER < 0x10100000L + SSL_library_init (); + // XXX: this list is probably not complete + atexit (EVP_cleanup); + SSL_load_error_strings (); + atexit (ERR_free_strings); +#else + // Cleanup is done automatically via atexit() + OPENSSL_init_ssl (0, NULL); +#endif +} + // --- To be moved to liberty -------------------------------------------------- static ssize_t |