From c3c8afa2d663b9fd6b1dfce8a44910d4b9c71386 Mon Sep 17 00:00:00 2001 From: Stu Hood Date: Mon, 27 Aug 2018 17:05:30 -0700 Subject: [PATCH] Shut down remote components in the correct order (caught by a unit test: excellent!). --- src/rust/engine/fs/src/store.rs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/src/rust/engine/fs/src/store.rs b/src/rust/engine/fs/src/store.rs index ca65849e494..56935140cb6 100644 --- a/src/rust/engine/fs/src/store.rs +++ b/src/rust/engine/fs/src/store.rs @@ -1637,12 +1637,10 @@ mod remote { where F: FnOnce() -> (), { - self.channel.with_reset(|| { - self.env.with_reset(|| { - self - .cas_client - .with_reset(|| self.byte_stream_client.with_reset(f)) - }) + self.cas_client.with_reset(|| { + self + .byte_stream_client + .with_reset(|| self.channel.with_reset(|| self.env.with_reset(f))) }) }