mirror of
https://codeberg.org/anoncontributorxmr/monero.git
synced 2024-11-27 13:23:29 +01:00
Fix #1824 don't end batch that we didn't start
This commit is contained in:
parent
4e92ef4aa4
commit
296641e047
@ -222,7 +222,7 @@ bool HardFork::reorganize_from_block_height(uint64_t height)
|
|||||||
return false;
|
return false;
|
||||||
|
|
||||||
db.set_batch_transactions(true);
|
db.set_batch_transactions(true);
|
||||||
db.batch_start();
|
bool stop_batch = db.batch_start();
|
||||||
|
|
||||||
versions.clear();
|
versions.clear();
|
||||||
|
|
||||||
@ -250,6 +250,7 @@ bool HardFork::reorganize_from_block_height(uint64_t height)
|
|||||||
add(db.get_block_from_height(h), h);
|
add(db.get_block_from_height(h), h);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (stop_batch)
|
||||||
db.batch_stop();
|
db.batch_stop();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
Loading…
Reference in New Issue
Block a user