Software /
code /
prosody
Comparison
plugins/mod_csi_simple.lua @ 10414:51ebfdeccad7
mod_csi_simple: Make sure to disable optimizations before mod_smacks (thanks pep.)
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Sun, 17 Nov 2019 17:59:56 +0100 |
parent | 10303:c434bff22b14 |
child | 10724:7835b9f14cb8 |
comparison
equal
deleted
inserted
replaced
10413:604096ce2f82 | 10414:51ebfdeccad7 |
---|---|
114 end); | 114 end); |
115 | 115 |
116 module:hook("pre-resource-unbind", function (event) | 116 module:hook("pre-resource-unbind", function (event) |
117 local session = event.session; | 117 local session = event.session; |
118 disable_optimizations(session); | 118 disable_optimizations(session); |
119 end); | 119 end, 1); |
120 | 120 |
121 module:hook("c2s-ondrain", function (event) | 121 module:hook("c2s-ondrain", function (event) |
122 local session = event.session; | 122 local session = event.session; |
123 if session.state == "inactive" and session.conn and session.conn.pause_writes then | 123 if session.state == "inactive" and session.conn and session.conn.pause_writes then |
124 session.conn:pause_writes(); | 124 session.conn:pause_writes(); |