Software /
code /
prosody
Changeset
941:13ebec89b568
Automated merge with ssh://hg@prosody.im/prosody-hg
author | Matthew Wild <mwild1@gmail.com> |
---|---|
date | Mon, 30 Mar 2009 20:04:31 +0100 |
parents | 939:b832f786af62 (current diff) 940:776cb8c847c5 (diff) |
children | 942:dae54304967d |
files | prosody |
diffstat | 1 files changed, 5 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/prosody Mon Mar 30 06:07:21 2009 +0500 +++ b/prosody Mon Mar 30 20:04:31 2009 +0100 @@ -110,9 +110,13 @@ ----------- End of out-of-place code -------------- - eventmanager.fire_event("server-starting"); +local global_ssl_ctx = config.get("*", "core", "ssl"); +if global_ssl_ctx then + local default_ssl_ctx = { mode = "server", protocol = "sslv23", capath = "/etc/ssl/certs", verify = "none"; }; + setmetatable(global_ssl_ctx, { __index = default_ssl_ctx }); +end -- start listening on sockets function net_activate_ports(option, listener, default, conntype) @@ -147,12 +151,6 @@ -- setup error handling setmetatable(_G, { __index = function (t, k) error("Attempt to read a non-existent global '"..k.."'", 2); end, __newindex = function (t, k, v) error("Attempt to set a global: "..tostring(k).." = "..tostring(v), 2); end }); -local global_ssl_ctx = config.get("*", "core", "ssl"); -if global_ssl_ctx then - local default_ssl_ctx = { mode = "server", protocol = "sslv23", capath = "/etc/ssl/certs", verify = "none"; }; - setmetatable(global_ssl_ctx, { __index = default_ssl_ctx }); -end - eventmanager.fire_event("server-started"); local quitting;