mirror of
https://git.postgresql.org/git/postgresql.git
synced 2024-12-21 08:29:39 +08:00
Avoid "unused variable" warning on non-USE_SSL_ENGINE platforms.
If we are building with openssl but USE_SSL_ENGINE didn't get set, initialize_SSL's variable "pkey" is declared but used nowhere. Apparently this combination hasn't been exercised in the buildfarm before now, because I've not seen this warning before, even though the code has been like this a long time. Move the declaration to silence the warning (and remove its useless initialization). Per buildfarm member sawshark. Back-patch to all supported branches.
This commit is contained in:
parent
30fe8a7ba0
commit
8f8511d477
@ -775,7 +775,6 @@ initialize_SSL(PGconn *conn)
|
||||
bool have_homedir;
|
||||
bool have_cert;
|
||||
bool have_rootcert;
|
||||
EVP_PKEY *pkey = NULL;
|
||||
|
||||
/*
|
||||
* We'll need the home directory if any of the relevant parameters are
|
||||
@ -1009,6 +1008,7 @@ initialize_SSL(PGconn *conn)
|
||||
/* Colon, but not in second character, treat as engine:key */
|
||||
char *engine_str = strdup(conn->sslkey);
|
||||
char *engine_colon;
|
||||
EVP_PKEY *pkey;
|
||||
|
||||
if (engine_str == NULL)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user