Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

Use current atomic update API in test helper

Neeraj Guptacedbde2422aa
diff --git a/rust/crates/test-support/src/object_store.rs b/rust/crates/test-support/src/object_store.rs
index b689b53bb8..3bde7242db 100644
--- a/rust/crates/test-support/src/object_store.rs
+++ b/rust/crates/test-support/src/object_store.rs
@@ -203,7 +203,7 @@ fn handle(stream: TcpStream, root: &Path, control: &ObjectStoreControl) -> TestR
};
if control
.interrupted
- .fetch_update(Ordering::SeqCst, Ordering::SeqCst, |left| {
+ .try_update(Ordering::SeqCst, Ordering::SeqCst, |left| {
left.checked_sub(1)
})
.is_ok()