aboutsummaryrefslogtreecommitdiff
path: root/src/blockchain_db/berkeleydb/db_bdb.h
diff options
context:
space:
mode:
authorThomas Winget <tewinget@gmail.com>2015-03-16 09:14:51 -0400
committerThomas Winget <tewinget@gmail.com>2015-03-16 09:14:51 -0400
commit43477b7dac861a83ade364ebb5a5c3da8228b3e4 (patch)
tree8ac746edc7275924353fc8ffbe1556d615b2ccfe /src/blockchain_db/berkeleydb/db_bdb.h
parentCMake wiring, minor cleanup, minor test addition (diff)
downloadmonero-43477b7dac861a83ade364ebb5a5c3da8228b3e4.tar.xz
BerkeleyDB Blockchain building, not working yet
Everything except actually *using* BlockchainBDB is wired up, but the db itself is not yet working. Some error about user mem not large enough. I think I know what this error means, but I can't determine the cause. Notes: BerkeleyDB does not allow 0-indexing in its recno type databases, so block numbers *in the database* will be 1-indexed. Modifications to indexing have been made as needed.
Diffstat (limited to 'src/blockchain_db/berkeleydb/db_bdb.h')
-rw-r--r--src/blockchain_db/berkeleydb/db_bdb.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/blockchain_db/berkeleydb/db_bdb.h b/src/blockchain_db/berkeleydb/db_bdb.h
index b28afbf20..f804db515 100644
--- a/src/blockchain_db/berkeleydb/db_bdb.h
+++ b/src/blockchain_db/berkeleydb/db_bdb.h
@@ -49,7 +49,7 @@ struct bdb_txn_safe
message = "Failed to commit a transaction to the db";
}
- if (txn->commit())
+ if (m_txn->commit(0))
{
m_txn = NULL;
LOG_PRINT_L0(message);
@@ -103,6 +103,8 @@ public:
virtual std::vector<std::string> get_filenames() const;
+ virtual std::string get_db_name() const;
+
virtual bool lock();
virtual void unlock();
@@ -279,7 +281,7 @@ private:
uint64_t m_height;
uint64_t m_num_outputs;
std::string m_folder;
- txn_safe m_write_txn; // may point to either a short-lived txn or a batch txn
+ bdb_txn_safe *m_write_txn;
bool m_batch_transactions; // support for batch transactions
};