aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2023-05-01 15:10:32 +0200
committerKim Alvefur <zash@zash.se>2023-05-01 15:10:32 +0200
commit8ef7bc2cf4d430c96e2b9b1876ba406c7c03aba9 (patch)
tree256154ae85eec1d1bb68b5ce0fd58a0073211ddc /plugins
parent9aecb5cd1998fae1c572e91a319c7610746c74b4 (diff)
downloadprosody-8ef7bc2cf4d430c96e2b9b1876ba406c7c03aba9.tar.gz
prosody-8ef7bc2cf4d430c96e2b9b1876ba406c7c03aba9.zip
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.
Diffstat (limited to 'plugins')
-rw-r--r--plugins/mod_csi_simple.lua4
1 files changed, 4 insertions, 0 deletions
diff --git a/plugins/mod_csi_simple.lua b/plugins/mod_csi_simple.lua
index 39b05b07..fdd1fd6c 100644
--- a/plugins/mod_csi_simple.lua
+++ b/plugins/mod_csi_simple.lua
@@ -161,6 +161,10 @@ function enable_optimizations(session)
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