diff options
author | lloyd <[email protected]> | 2014-01-18 22:37:19 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2014-01-18 22:37:19 +0000 |
commit | 700ae0440c1fac65a218fc2ae5883bdc63683f08 (patch) | |
tree | faab5bcdf076b2e25a783755c3f7792f93869c6a /src/lib/tls/sessions_sqlite | |
parent | a769d409b252f62d97e9f71dd38a7131f8b8155e (diff) |
More unique_ptr
Diffstat (limited to 'src/lib/tls/sessions_sqlite')
-rw-r--r-- | src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.cpp | 1 | ||||
-rw-r--r-- | src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.h | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.cpp b/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.cpp index d4f286a8d..bddb7822c 100644 --- a/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.cpp +++ b/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.cpp @@ -119,7 +119,6 @@ Session_Manager_SQLite::Session_Manager_SQLite(const std::string& passphrase, Session_Manager_SQLite::~Session_Manager_SQLite() { - delete m_db; } bool Session_Manager_SQLite::load_from_session_id(const std::vector<byte>& session_id, diff --git a/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.h b/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.h index 7892ccd6a..04e8135a8 100644 --- a/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.h +++ b/src/lib/tls/sessions_sqlite/tls_session_manager_sqlite.h @@ -10,6 +10,7 @@ #include <botan/tls_session_manager.h> #include <botan/rng.h> +#include <memory> namespace Botan { @@ -70,7 +71,7 @@ class BOTAN_DLL Session_Manager_SQLite : public Session_Manager RandomNumberGenerator& m_rng; size_t m_max_sessions; std::chrono::seconds m_session_lifetime; - sqlite3_database* m_db; + std::unique_ptr<sqlite3_database> m_db; }; } |