[gnome-terminal] Don't split URL having a colon (":") in the middle
- From: Tomas Bzatek <tbzatek src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-terminal] Don't split URL having a colon (":") in the middle
- Date: Tue, 2 Aug 2011 13:06:36 +0000 (UTC)
commit 1eb9a8283fec7d1cc7492deb53d6705b52538b5c
Author: Tomas Bzatek <tbzatek redhat com>
Date: Tue Aug 2 15:06:14 2011 +0200
Don't split URL having a colon (":") in the middle
Properly handle links like
http://foo.bar/path/with/a/colon:foo
This patch also avoids selecting trailing colon.
https://bugzilla.gnome.org/show_bug.cgi?id=640727
src/terminal-screen.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/terminal-screen.c b/src/terminal-screen.c
index 02d0d3f..acfd5d8 100644
--- a/src/terminal-screen.c
+++ b/src/terminal-screen.c
@@ -150,8 +150,8 @@ static guint signals[LAST_SIGNAL];
#define HOSTCHARS_CLASS "[-[:alnum:]]"
#define HOST HOSTCHARS_CLASS "+(\\." HOSTCHARS_CLASS "+)*"
#define PORT "(?:\\:[[:digit:]]{1,5})?"
-#define PATHCHARS_CLASS "[-[:alnum:]\\Q_$.+!*,;@&=?/~#%\\E]"
-#define PATHTERM_CLASS "[^\\Q]'.}>) \t\r\n,\"\\E]"
+#define PATHCHARS_CLASS "[-[:alnum:]\\Q_$.+!*,:;@&=?/~#%\\E]"
+#define PATHTERM_CLASS "[^\\Q]'.:}>) \t\r\n,\"\\E]"
#define SCHEME "(?:news:|telnet:|nntp:|file:\\/|https?:|ftps?:|sftp:|webcal:)"
#define USERPASS USERCHARS_CLASS "+(?:" PASSCHARS_CLASS "+)?"
#define URLPATH "(?:(/"PATHCHARS_CLASS"+(?:[(]"PATHCHARS_CLASS"*[)])*"PATHCHARS_CLASS"*)*"PATHTERM_CLASS")?"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]