Sqlite: Fix warnings

- use of uninitialized value
- unused local typedef

Change-Id: I60d6c3a9a04d9f603a102439582c9e55d85a191f
Reviewed-by: Marco Bubke <marco.bubke@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
This commit is contained in:
Christian Kandeler
2021-06-24 10:55:02 +02:00
parent b1837036b3
commit 627dd6681b
2 changed files with 1 additions and 3 deletions

View File

@@ -213,7 +213,7 @@ public:
auto value(const QueryTypes &...queryValues)
{
Resetter resetter{this};
ResultType resultValue;
ResultType resultValue{};
bindValues(queryValues...);

View File

@@ -1474,7 +1474,6 @@ TEST_F(SqliteStatement, ReadStatementOptionalValueWithTransactions)
TEST_F(SqliteStatement, ReadStatementReadCallbackWithTransactions)
{
using Tuple = std::tuple<Utils::SmallString, Utils::SmallString, long long>;
MockFunction<Sqlite::CallbackControl(Utils::SmallStringView, Utils::SmallStringView, long long)> callbackMock;
ReadStatement<3> statement("SELECT name, number, value FROM test WHERE name=? AND number=?",
database);
@@ -1541,7 +1540,6 @@ TEST_F(SqliteStatement, ReadWriteStatementOptionalValueWithTransactions)
TEST_F(SqliteStatement, ReadWriteStatementReadCallbackWithTransactions)
{
using Tuple = std::tuple<Utils::SmallString, Utils::SmallString, long long>;
MockFunction<Sqlite::CallbackControl(Utils::SmallStringView, Utils::SmallStringView, long long)> callbackMock;
ReadWriteStatement<3> statement(
"SELECT name, number, value FROM test WHERE name=? AND number=?", database);