mirror of
https://github.com/Xahau/xahaud.git
synced 2025-12-06 17:27:52 +00:00
Simplify locking and move a typedef.
* Make DatabaseCon's lock private and expose a scoped lock_guard. * Get rid of DeprecatedRecursiveMutex and DeprecatedScopedLock entirely. * Move CancelCallback to Job where it logically belongs.
This commit is contained in:
committed by
Vinnie Falco
parent
02c2029ac1
commit
6335e34395
@@ -80,7 +80,7 @@ public:
|
||||
pObject->reset ();
|
||||
|
||||
{
|
||||
DeprecatedScopedLock sl (m_db->getDBLock());
|
||||
auto sl (m_db->lock());
|
||||
|
||||
uint256 const hash (uint256::fromVoid (key));
|
||||
|
||||
@@ -124,7 +124,7 @@ public:
|
||||
{
|
||||
// VFALCO TODO Rewrite this to use Beast::db
|
||||
|
||||
DeprecatedScopedLock sl (m_db->getDBLock());
|
||||
auto sl (m_db->lock());
|
||||
|
||||
static SqliteStatement pStB (m_db->getDB()->getSqliteDB(), "BEGIN TRANSACTION;");
|
||||
static SqliteStatement pStE (m_db->getDB()->getSqliteDB(), "END TRANSACTION;");
|
||||
|
||||
Reference in New Issue
Block a user