You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

42 lines
1.0 KiB

  1. --- a/src/main.c
  2. +++ b/src/main.c
  3. @@ -965,10 +965,12 @@ main(int argc, char **argv)
  4. sigprocmask(SIG_BLOCK, &set, NULL);
  5. trap_init(argv[0]);
  6. +#if OPENSSL_VERSION_NUMBER < 0x10100000L
  7. /* SSL library init */
  8. OPENSSL_config(NULL);
  9. SSL_load_error_strings();
  10. SSL_library_init();
  11. +#endif
  12. /* Initialise configuration */
  13. notify_init();
  14. @@ -1159,8 +1161,11 @@ main(int argc, char **argv)
  15. #endif
  16. free(opt_satip_xml.str);
  17. +#if OPENSSL_VERSION_NUMBER < 0x10100000L
  18. /* OpenSSL - welcome to the "cleanup" hell */
  19. +#ifndef OPENSSL_NO_ENGINE
  20. ENGINE_cleanup();
  21. +#endif
  22. RAND_cleanup();
  23. CRYPTO_cleanup_all_ex_data();
  24. EVP_cleanup();
  25. @@ -1168,12 +1173,13 @@ main(int argc, char **argv)
  26. #ifndef OPENSSL_NO_COMP
  27. COMP_zlib_cleanup();
  28. #endif
  29. - ERR_remove_state(0);
  30. + ERR_remove_thread_state(NULL);
  31. ERR_free_strings();
  32. #ifndef OPENSSL_NO_COMP
  33. sk_SSL_COMP_free(SSL_COMP_get_compression_methods());
  34. #endif
  35. /* end of OpenSSL cleanup code */
  36. +#endif
  37. #if ENABLE_DBUS_1
  38. extern void dbus_shutdown(void);