Remove obsolete pointer indirection, fix warnings and a leak

Leak: The sqlite3 connection handle destructor was
accidentally turned into a default constructor during the
migration of repositories.

Replaced the sqlite3 raw pointer with a unique_ptr to prevent
this kind of accident.
This commit is contained in:
Roland Bock
2022-01-10 07:40:36 +01:00
parent 23ae65dd67
commit d6aef0fa9b
6 changed files with 73 additions and 72 deletions

View File

@@ -57,7 +57,7 @@ int Transaction(int, char*[])
std::cout << "Expecting default isolation level = 1, is " << static_cast<int>(current_level) << std::endl;
assert(current_level == sqlpp::isolation_level::serializable);
int pragmaValue = db(custom_query(sqlpp::verbatim("PRAGMA read_uncommitted"))
int64_t pragmaValue = db(custom_query(sqlpp::verbatim("PRAGMA read_uncommitted"))
.with_result_type_of(select(sqlpp::value(1).as(pragma))))
.front()
.pragma;