From 38a6b3e69f4197d4f89918743f03dd17250d3b22 Mon Sep 17 00:00:00 2001 From: yhirose Date: Sun, 19 Apr 2020 22:04:29 -0400 Subject: [PATCH] Fixed warning --- httplib.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/httplib.h b/httplib.h index 1257d38..db9e65e 100644 --- a/httplib.h +++ b/httplib.h @@ -4551,11 +4551,11 @@ public: private: static void locking_callback(int mode, int type, const char * /*file*/, int /*line*/) { - auto &locks = *openSSL_locks_; + auto &lk = (*openSSL_locks_)[static_cast(type)]; if (mode & CRYPTO_LOCK) { - locks[type].lock(); + lk.lock(); } else { - locks[type].unlock(); + lk.unlock(); } } };