Skip to content

Commit f754e1c

Browse files
authored
Fix build error on OpenBSD (#298)
1 parent 26a5998 commit f754e1c

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

trantor/utils/Logger.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -393,7 +393,7 @@ void Logger::enableSpdLog(int index, std::shared_ptr<spdlog::logger> logger)
393393
spdLoggers[index] = logger ? logger : getDefaultSpdLogger(index);
394394
#else
395395
(void)index;
396-
(bool)logger;
396+
(void)logger;
397397
#endif // TRANTOR_SPDLOG_SUPPORT
398398
}
399399

trantor/utils/crypto/openssl.cc

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,8 +87,8 @@ Hash256 sha256(const void* data, size_t len)
8787

8888
Hash256 sha3(const void* data, size_t len)
8989
{
90-
#if OPENSSL_VERSION_MAJOR >= 3
9190
Hash256 hash;
91+
#if OPENSSL_VERSION_MAJOR >= 3
9292
auto sha3 = EVP_MD_fetch(nullptr, "SHA3-256", nullptr);
9393
if (sha3 != nullptr)
9494
{
@@ -101,7 +101,6 @@ Hash256 sha3(const void* data, size_t len)
101101
return hash;
102102
}
103103
#elif !defined(LIBRESSL_VERSION_NUMBER)
104-
Hash256 hash;
105104
auto sha3 = EVP_sha3_256();
106105
if (sha3 != nullptr)
107106
{

0 commit comments

Comments
 (0)