[smuxi/stable] Engine: fix parsing IP links with ports on Mono >= 4.1
- From: Mirco M. M. Bauer <mmmbauer src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [smuxi/stable] Engine: fix parsing IP links with ports on Mono >= 4.1
- Date: Wed, 19 Oct 2016 17:09:02 +0000 (UTC)
commit f3dbc1b36ef26cd53efc1f5ddb29475196080ea5
Author: Mirco Bauer <meebey meebey net>
Date: Thu Oct 20 01:03:28 2016 +0800
Engine: fix parsing IP links with ports on Mono >= 4.1
With Mono 4.1 the regex parser was replaced with the open-sourced Microsoft
implementation. The MS implementation does not treat [0-9]{,4} to mean that a
number can have between 0 and 4 occurrences.
src/Engine/Config/MessageBuilderSettings.cs | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/Engine/Config/MessageBuilderSettings.cs b/src/Engine/Config/MessageBuilderSettings.cs
index 0dd15b4..27900f3 100644
--- a/src/Engine/Config/MessageBuilderSettings.cs
+++ b/src/Engine/Config/MessageBuilderSettings.cs
@@ -83,7 +83,7 @@ namespace Smuxi.Engine
string domain = @"(?:(?:" + subdomain + ")+(?:" + any_tld + ")|localhost)";
string bare_host = @"[a-z]+";
string host = "(?:" + domain + "|" + bare_host + "|" + ip + ")";
- string short_number = "[1-9][0-9]{,4}";
+ string short_number = "[1-9][0-9]{0,4}";
string port = ":" + short_number;
string user = "[a-z0-9._%+-]+@";
string host_port = host + "(?:" + port + ")?";
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]