Protect wallet data file with a file lock
Operations on the wallet data file are now fenced by a lock to avoid potentially messy concurrent modifications by multiple processes (i.e. the wallet receiver and a send command). The lock is done using a create-only lock file, which is an atomic operation.
This commit is contained in:
@@ -114,7 +114,6 @@ impl<T> TransactionPool<T> where T: BlockChain {
|
||||
// Making sure the transaction is valid before anything else.
|
||||
let secp = secp::Secp256k1::with_caps(secp::ContextFlag::Commit);
|
||||
tx.validate(&secp).map_err(|_| PoolError::Invalid)?;
|
||||
|
||||
|
||||
// The first check invovles ensuring that an identical transaction is
|
||||
// not already in the pool's transaction set.
|
||||
|
||||
Reference in New Issue
Block a user