mirror of
https://github.com/bitcoin/bitcoin.git
synced 2024-05-17 23:56:39 +00:00
Implement SQLiteDatabaseVersion
This commit is contained in:
parent
7577b6e1c8
commit
ca8b7e04ab
@ -9,6 +9,7 @@
|
|||||||
#include <util/translation.h>
|
#include <util/translation.h>
|
||||||
#include <wallet/db.h>
|
#include <wallet/db.h>
|
||||||
|
|
||||||
|
#include <sqlite3.h>
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
static const char* const DATABASE_FILENAME = "wallet.dat";
|
static const char* const DATABASE_FILENAME = "wallet.dat";
|
||||||
@ -107,3 +108,8 @@ std::unique_ptr<SQLiteDatabase> MakeSQLiteDatabase(const fs::path& path, const D
|
|||||||
{
|
{
|
||||||
return MakeUnique<SQLiteDatabase>(path, path / DATABASE_FILENAME);
|
return MakeUnique<SQLiteDatabase>(path, path / DATABASE_FILENAME);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
std::string SQLiteDatabaseVersion()
|
||||||
|
{
|
||||||
|
return std::string(sqlite3_libversion());
|
||||||
|
}
|
||||||
|
@ -96,4 +96,6 @@ public:
|
|||||||
bool ExistsSQLiteDatabase(const fs::path& path);
|
bool ExistsSQLiteDatabase(const fs::path& path);
|
||||||
std::unique_ptr<SQLiteDatabase> MakeSQLiteDatabase(const fs::path& path, const DatabaseOptions& options, DatabaseStatus& status, bilingual_str& error);
|
std::unique_ptr<SQLiteDatabase> MakeSQLiteDatabase(const fs::path& path, const DatabaseOptions& options, DatabaseStatus& status, bilingual_str& error);
|
||||||
|
|
||||||
|
std::string SQLiteDatabaseVersion();
|
||||||
|
|
||||||
#endif // BITCOIN_WALLET_SQLITE_H
|
#endif // BITCOIN_WALLET_SQLITE_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user