Software /
code /
prosody
Comparison
plugins/mod_csi_simple.lua @ 13090:3cea237f9d1d 0.12
mod_csi_simple: Clear delayed active mode timer on disable
It should not be there afterwards. Noticed that it seems to fire some
time after resumption claiming that the queue size is nil, implying
that it may hold a reference to an expired session somehow.
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Mon, 01 May 2023 14:52:38 +0200 |
parent | 12234:1c47162dd965 |
child | 13091:214a679823e8 |
comparison
equal
deleted
inserted
replaced
13078:6da83deb8d7f | 13090:3cea237f9d1d |
---|---|
170 | 170 |
171 function disable_optimizations(session) | 171 function disable_optimizations(session) |
172 filters.remove_filter(session, "stanzas/out", manage_buffer); | 172 filters.remove_filter(session, "stanzas/out", manage_buffer); |
173 filters.remove_filter(session, "bytes/in", flush_buffer); | 173 filters.remove_filter(session, "bytes/in", flush_buffer); |
174 session.csi_counter = nil; | 174 session.csi_counter = nil; |
175 if session.csi_resume then | |
176 timer.stop(session.csi_resume); | |
177 session.csi_resume = nil; | |
178 end | |
175 if session.csi_measure_buffer_hold then | 179 if session.csi_measure_buffer_hold then |
176 session.csi_measure_buffer_hold(); | 180 session.csi_measure_buffer_hold(); |
177 session.csi_measure_buffer_hold = nil; | 181 session.csi_measure_buffer_hold = nil; |
178 end | 182 end |
179 if session.conn and session.conn.resume_writes then | 183 if session.conn and session.conn.resume_writes then |