From 6521b0e6612036ceb4d4db1a8e6a99ac3d3a4ec2 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Sat, 28 Apr 2012 18:45:04 +0100 Subject: portmanager: Ensure port is always a number (thanks Zash) --- core/portmanager.lua | 1 + 1 file changed, 1 insertion(+) diff --git a/core/portmanager.lua b/core/portmanager.lua index 3bd143ef..5f53b61c 100644 --- a/core/portmanager.lua +++ b/core/portmanager.lua @@ -112,6 +112,7 @@ function activate(service_name) for interface in bind_interfaces do for port in bind_ports do + port = tonumber(port); if #active_services:search(nil, interface, port) > 0 then log("error", "Multiple services configured to listen on the same port ([%s]:%d): %s, %s", interface, port, active_services:search(nil, interface, port)[1][1].service.name or "", service_name or ""); else -- cgit v1.2.3