componentmanager: Fix oops in pattern for matching subdomain
authorMatthew Wild <mwild1@gmail.com>
Fri, 09 Oct 2009 00:15:39 +0100
changeset 1940 85d51cea2c4c
parent 1939 2c295826a96d
child 1941 3f765fde5149
componentmanager: Fix oops in pattern for matching subdomain
core/componentmanager.lua
--- a/core/componentmanager.lua	Thu Oct 08 23:51:55 2009 +0100
+++ b/core/componentmanager.lua	Fri Oct 09 00:15:39 2009 +0100
@@ -75,7 +75,7 @@
 		-- We need to find SSL context to use...
 		-- Discussion in prosody@ concluded that
 		-- 1 level back is usually enough by default
-		local base_host = host:gsub("^[^%.]+", "");
+		local base_host = host:gsub("^[^%.]+%.", "");
 		if hosts[base_host] then
 			ssl_ctx = hosts[base_host].ssl_ctx;
 		end