Changeset

13091:214a679823e8 0.12

mod_csi_simple: Disable revert-to-inactive timer when going to active mode This timer shouldn't kick in in the middle of active mode.
author Kim Alvefur <zash@zash.se>
date Mon, 01 May 2023 15:10:32 +0200
parents 13090:3cea237f9d1d
children 13092:bc46cfe7c037 13110:d5f322dd424b
files plugins/mod_csi_simple.lua
diffstat 1 files changed, 4 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_csi_simple.lua	Mon May 01 14:52:38 2023 +0200
+++ b/plugins/mod_csi_simple.lua	Mon May 01 15:10:32 2023 +0200
@@ -161,6 +161,10 @@
 		session.conn:pause_writes();
 		session.csi_measure_buffer_hold = measure_buffer_hold();
 		session.csi_counter = 0;
+		if session.csi_resume then
+			timer.stop(session.csi_resume);
+			session.csi_resume = nil;
+		end
 		filters.add_filter(session, "stanzas/out", manage_buffer);
 		filters.add_filter(session, "bytes/in", flush_buffer);
 	else