Code review: Hold another lock during eviction

This commit is contained in:
Kirill Bulatov
2023-01-31 14:32:50 +02:00
parent b654687b3f
commit eab1f375e6

View File

@@ -888,6 +888,7 @@ impl Timeline {
LayerFileName::Test(_) => unreachable!(),
});
let mut _gc_lock = self.layer_removal_cs.lock().await;
let mut layers = self.layers.write().unwrap();
let mut updates = layers.batch_update();
self.delete_historic_layer(local_layer, &mut updates)?;