kernel/block_cache: Adjust logic in cache_detach_sub_transaction.
This way it should be more clear that parent_data is being modified in tandem with original_data. No functional change intended.
This commit is contained in:
parent
e12a5fe215
commit
8a2d11b7dc
4
src/system/kernel/cache/block_cache.cpp
vendored
4
src/system/kernel/cache/block_cache.cpp
vendored
@ -3055,15 +3055,15 @@ cache_detach_sub_transaction(void* _cache, int32 id,
|
||||
if (block->parent_data != block->current_data) {
|
||||
// The block had been changed in both transactions
|
||||
block->original_data = block->parent_data;
|
||||
block->parent_data = NULL;
|
||||
} else {
|
||||
// The block has only been changed in the parent
|
||||
block->original_data = NULL;
|
||||
block->original_data = block->parent_data = NULL;
|
||||
}
|
||||
|
||||
// move the block to the previous transaction list
|
||||
transaction->blocks.Add(block);
|
||||
block->previous_transaction = transaction;
|
||||
block->parent_data = NULL;
|
||||
}
|
||||
|
||||
if (block->original_data != NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user