Software /
code /
prosody
Diff
core/portmanager.lua @ 6041:a97591d2e1ad
portmanager: Make maximum read size configurable, and default to 4KB
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Sun, 30 Mar 2014 08:44:55 +0100 |
parent | 5550:557583904dc5 |
child | 6054:7a5ddbaf758d |
child | 7077:0386ccf20ac7 |
line wrap: on
line diff
--- a/core/portmanager.lua Tue Feb 18 20:03:12 2014 +0100 +++ b/core/portmanager.lua Sun Mar 30 08:44:55 2014 +0100 @@ -29,6 +29,8 @@ table.insert(default_local_interfaces, "::1"); end +local default_mode = config.get("*", "network_default_read_size") or 4096; + --- Private state -- service_name -> { service_info, ... } @@ -111,7 +113,7 @@ } bind_ports = set.new(type(bind_ports) ~= "table" and { bind_ports } or bind_ports ); - local mode, ssl = listener.default_mode or "*a"; + local mode, ssl = listener.default_mode or default_mode; local hooked_ports = {}; for interface in bind_interfaces do