diff options
author | Kim Alvefur <zash@zash.se> | 2020-08-02 00:22:57 +0200 |
---|---|---|
committer | Kim Alvefur <zash@zash.se> | 2020-08-02 00:22:57 +0200 |
commit | 8fae7acf319d7ff48a12f62e208ddd62665c81ba (patch) | |
tree | 4f4477f69bd86bb0a94032c2daadd81ba1e3ce61 | |
parent | 933c04882934fdc8633c93e706c8b28c977f776e (diff) | |
download | prosody-8fae7acf319d7ff48a12f62e208ddd62665c81ba.tar.gz prosody-8fae7acf319d7ff48a12f62e208ddd62665c81ba.zip |
mod_net_multiplex: Read no more than the max buffer size setting
Otherwise the '*a' read mode applies, which under certain circumstances
can read infinite amounts of data into memory.
-rw-r--r-- | plugins/mod_net_multiplex.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_net_multiplex.lua b/plugins/mod_net_multiplex.lua index 849b22ee..42a41709 100644 --- a/plugins/mod_net_multiplex.lua +++ b/plugins/mod_net_multiplex.lua @@ -41,7 +41,7 @@ end local buffers = {}; -local listener = { default_mode = "*a" }; +local listener = { default_mode = max_buffer_len }; function listener.onconnect(conn) local sock = conn:socket(); |