From cedf4412818fe15cdbd269a443c27d695106e69e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?louiz=E2=80=99?= Date: Sun, 3 Nov 2019 22:20:44 +0100 Subject: Use the right int64 type for INTEGER rows in the db --- src/database/database.hpp | 8 ++++---- src/database/query.hpp | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/database/database.hpp b/src/database/database.hpp index 4a413be..a53f87b 100644 --- a/src/database/database.hpp +++ b/src/database/database.hpp @@ -63,8 +63,8 @@ class Database struct EncodingIn: Column { static constexpr auto name = "encodingin_"; }; - struct MaxHistoryLength: Column { static constexpr auto name = "maxhistorylength_"; - MaxHistoryLength(): Column(20) {} }; + struct MaxHistoryLength: Column { static constexpr auto name = "maxhistorylength_"; + MaxHistoryLength(): Column(20) {} }; struct RecordHistory: Column { static constexpr auto name = "recordhistory_"; RecordHistory(): Column(true) {}}; @@ -86,8 +86,8 @@ class Database struct Address: Column { static constexpr auto name = "address_"; }; - struct ThrottleLimit: Column { static constexpr auto name = "throttlelimit_"; - ThrottleLimit(): Column(10) {} }; + struct ThrottleLimit: Column { static constexpr auto name = "throttlelimit_"; + ThrottleLimit(): Column(10) {} }; using MucLogLineTable = Table; using MucLogLine = MucLogLineTable::RowType; diff --git a/src/database/query.hpp b/src/database/query.hpp index ae6e946..c89371f 100644 --- a/src/database/query.hpp +++ b/src/database/query.hpp @@ -18,7 +18,7 @@ void actual_bind(Statement& statement, const T& value, int index) { static_assert(std::is_integral::value, "Only a string, an optional-bool or an integer can be used."); - statement.bind_int64(index, static_cast(value)); + statement.bind_int64(index, static_cast(value)); } #ifdef DEBUG_SQL_QUERIES -- cgit v1.2.3