From ce9149dc067912fba4928350c2a9848712c8dd62 Mon Sep 17 00:00:00 2001 From: "Brian L. Troutwine" Date: Tue, 12 Nov 2024 11:53:13 -0800 Subject: [PATCH] scoot advance time back Signed-off-by: Brian L. Troutwine --- lading/src/generator/file_gen/logrotate_fs.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lading/src/generator/file_gen/logrotate_fs.rs b/lading/src/generator/file_gen/logrotate_fs.rs index 1e8f89fa6..1c4068414 100644 --- a/lading/src/generator/file_gen/logrotate_fs.rs +++ b/lading/src/generator/file_gen/logrotate_fs.rs @@ -366,6 +366,7 @@ impl Filesystem for LogrotateFS { ) { let tick = self.get_current_tick(); let mut state = self.state.lock().expect("lock poisoned"); + state.advance_time(tick); counter!("fs_release").increment(1); @@ -376,10 +377,8 @@ impl Filesystem for LogrotateFS { }; if let Some(file_handle) = file_handle { - // Close the file in the model, advance time. + // Close the file in the model state.close_file(tick, file_handle); - state.advance_time(tick); - reply.ok(); } else { reply.error(ENOENT);