Remove Boost Link Dependency
This commit is contained in:
@@ -1,15 +1,16 @@
|
||||
#ifndef UTIL_HTTPCLIENTHELPERS_H
|
||||
#define UTIL_HTTPCLIENTHELPERS_H
|
||||
|
||||
#include <boost/shared_ptr.hpp>
|
||||
#include <boost/thread.hpp>
|
||||
#include <memory>
|
||||
#include <mutex>
|
||||
#include <vector>
|
||||
#include <openssl/crypto.h>
|
||||
|
||||
|
||||
namespace PresenceDetection {
|
||||
namespace Util {
|
||||
|
||||
static std::vector<boost::shared_ptr<boost::mutex> > g_mutexes;
|
||||
static std::vector<std::shared_ptr<std::mutex> > g_mutexes;
|
||||
|
||||
static void LockCallback(int mode, int type, const char* /*file*/, int /*line*/)
|
||||
{
|
||||
@@ -28,7 +29,7 @@ static void InitializeLocks(void)
|
||||
{
|
||||
g_mutexes.resize(CRYPTO_num_locks());
|
||||
for (int i = 0; i < CRYPTO_num_locks(); ++i)
|
||||
g_mutexes[i] = boost::shared_ptr<boost::mutex>(new boost::mutex());
|
||||
g_mutexes[i] = std::shared_ptr<std::mutex>(new std::mutex());
|
||||
|
||||
CRYPTO_set_id_callback(ThreadId);
|
||||
CRYPTO_set_locking_callback(LockCallback);
|
||||
|
||||
Reference in New Issue
Block a user