Skip to content

Commit

Permalink
test: allow to run init_ssl() multiple times
Browse files Browse the repository at this point in the history
  • Loading branch information
azat committed Aug 13, 2022
1 parent 4ca417a commit a4cdc3c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions test/regress_openssl.c
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,11 @@ get_ssl_ctx(void)
void
init_ssl(void)
{
static int initialized;
if (initialized)
return;
initialized = 1;

#if (OPENSSL_VERSION_NUMBER < 0x10100000L) || \
(defined(LIBRESSL_VERSION_NUMBER) && \
LIBRESSL_VERSION_NUMBER < 0x20700000L)
Expand Down

0 comments on commit a4cdc3c

Please sign in to comment.