[smuxi/experiments/any_server_support: 14/34] Engine: fixed matching ports 1-9 in URLs



commit b6245b1c6c8823d553c69724c9ffe921dcc511d2
Author: Mirco Bauer <meebey meebey net>
Date:   Sun Jan 19 20:54:25 2014 +0100

    Engine: fixed matching ports 1-9 in URLs

 src/Engine/Config/MessageBuilderSettings.cs |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/src/Engine/Config/MessageBuilderSettings.cs b/src/Engine/Config/MessageBuilderSettings.cs
index 03734b2..ee1c435 100644
--- a/src/Engine/Config/MessageBuilderSettings.cs
+++ b/src/Engine/Config/MessageBuilderSettings.cs
@@ -71,7 +71,8 @@ namespace Smuxi.Engine
             string common_tld = @"de|es|im|us|com|net|org|info|biz|gov|name|edu|onion|museum";
             string tld = common_tld + @"|[a-z][a-z]";
             string domain = @"(?:(?:" + subdomain + ")+(?:" + tld + ")|localhost)";
-            string port = ":[1-9][0-9]{1,4}";
+            string short_number = "[1-9][0-9]{,4}";
+            string port = ":" + short_number;
             string user = "[a-z0-9._%+-]+@";
             string domain_port = domain + "(?:" + port + ")?";
             string user_domain = user + domain;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]