diff options
author | Matthew Wild <mwild1@gmail.com> | 2012-04-22 16:35:26 +0100 |
---|---|---|
committer | Matthew Wild <mwild1@gmail.com> | 2012-04-22 16:35:26 +0100 |
commit | 67f1c12639abc5053bda02077abba5bf02ca0c2f (patch) | |
tree | 2c4cd8df96e861f9606f711bccf0c5bcdc9cb32b /plugins/mod_component.lua | |
parent | d74cf643a6dc8f0eb12a8af4eba82f944c41aaf8 (diff) | |
download | prosody-67f1c12639abc5053bda02077abba5bf02ca0c2f.tar.gz prosody-67f1c12639abc5053bda02077abba5bf02ca0c2f.zip |
mod_component: Handle component connecting to non-existent host
Diffstat (limited to 'plugins/mod_component.lua')
-rw-r--r-- | plugins/mod_component.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/plugins/mod_component.lua b/plugins/mod_component.lua index 96d55e40..5b1eefc7 100644 --- a/plugins/mod_component.lua +++ b/plugins/mod_component.lua @@ -149,7 +149,7 @@ function stream_callbacks.error(session, error, data, data2) end function stream_callbacks.streamopened(session, attr) - if not hosts[attr.to].modules.component then + if not hosts[attr.to] or not hosts[attr.to].modules.component then session:close{ condition = "host-unknown", text = tostring(attr.to).." does not match any configured external components" }; return; end |