From 52f58114610969d7d166828be2c02aa1cc0bb44d Mon Sep 17 00:00:00 2001 From: Frank Park Date: Sat, 8 Apr 2017 10:58:24 -0400 Subject: [PATCH] bug fixes --- include/sqlpp11/pool_connection.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/include/sqlpp11/pool_connection.h b/include/sqlpp11/pool_connection.h index 0594a75a..05bad664 100644 --- a/include/sqlpp11/pool_connection.h +++ b/include/sqlpp11/pool_connection.h @@ -40,6 +40,8 @@ namespace sqlpp Connection_pool* origin; public: + pool_connection() : _impl(nullptr), origin(nullptr) {} + pool_connection(std::unique_ptr& connection, Connection_pool* origin) : _impl(std::move(connection)), origin(origin) {} @@ -86,7 +88,9 @@ namespace sqlpp pool_connection& operator=(const pool_connection&) = delete; pool_connection& operator=(pool_connection&& other) { - _impl(std::move(other._impl)), origin(other.origin); + _impl = std::move(other._impl); + origin = other.origin; + return *this; } }; }