Fixed initialisation of old GnuTLS versions

This commit is contained in:
Evgeny Grin (Karlson2k) committed 2022-09-25 18:39:40 +03:00
1 parent 8815effe66
commit 1e288041bd
21 files changed
+84 -82

No files matched your search

+4 -4
View File
@@ -28,9 +28,9 @@
#include <limits.h>
#include <sys/stat.h>
#include <curl/curl.h>
#ifdef MHD_HTTPS_REQUIRE_GRYPT
#ifdef MHD_HTTPS_REQUIRE_GCRYPT
#include <gcrypt.h>
#endif /* MHD_HTTPS_REQUIRE_GRYPT */
#endif /* MHD_HTTPS_REQUIRE_GCRYPT */
#include "tls_test_common.h"
#include <gnutls/gnutls.h>
@@ -264,12 +264,12 @@ main (int argc, char *const *argv)
else
port = 3060;
#ifdef MHD_HTTPS_REQUIRE_GRYPT
#ifdef MHD_HTTPS_REQUIRE_GCRYPT
gcry_control (GCRYCTL_ENABLE_QUICK_RANDOM, 0);
#ifdef GCRYCTL_INITIALIZATION_FINISHED
gcry_control (GCRYCTL_INITIALIZATION_FINISHED, 0);
#endif
#endif /* MHD_HTTPS_REQUIRE_GRYPT */
#endif /* MHD_HTTPS_REQUIRE_GCRYPT */
if (! testsuite_curl_global_init ())
return 99;
tls_backend = curl_version_info (CURLVERSION_NOW)->ssl_version;