[core] explicitly initialize a few fields to null

This commit is contained in:
Konstantin Käfer
2016-02-24 17:14:59 +01:00
committed by John Firebaugh
parent 661e9e7f49
commit 8112ac3371
6 changed files with 12 additions and 12 deletions

View File

@@ -72,7 +72,7 @@ public:
}
private:
sqlite3* db;
sqlite3* db = nullptr;
bool locked = false;
};
@@ -115,7 +115,7 @@ TEST(OfflineDatabase, SchemaVersion) {
std::string path("test/fixtures/database/offline.db");
{
sqlite3* db;
sqlite3* db = nullptr;
sqlite3_open_v2(path.c_str(), &db, SQLITE_OPEN_READWRITE | SQLITE_OPEN_CREATE, nullptr);
sqlite3_exec(db, "PRAGMA user_version = 1", nullptr, nullptr, nullptr);
sqlite3_close_v2(db);