[empathy] Make sure double quotes are not considered part of URIs
- From: Gustavo Noronha Silva <gns src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [empathy] Make sure double quotes are not considered part of URIs
- Date: Tue, 24 Nov 2009 16:51:13 +0000 (UTC)
commit d6c023acb730fd74dab269fd3f5883b0e655de5f
Author: Gustavo Noronha Silva <gustavo noronha collabora co uk>
Date: Tue Nov 24 14:27:58 2009 -0200
Make sure double quotes are not considered part of URIs
The fact that the URI regex we use to detect URIs in chat
conversations does not exclude double quotes causes it to pick up more
of the text than it should, in some cases.
Bug #598381
libempathy-gtk/empathy-ui-utils.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/libempathy-gtk/empathy-ui-utils.c b/libempathy-gtk/empathy-ui-utils.c
index 9ba0173..ce5ec41 100644
--- a/libempathy-gtk/empathy-ui-utils.c
+++ b/libempathy-gtk/empathy-ui-utils.c
@@ -51,8 +51,8 @@
#define SCHEMES "(https?|s?ftps?|nntp|news|javascript|about|ghelp|apt|telnet|"\
"file|webcal|mailto)"
-#define BODY "([^\\ \\n]+)"
-#define END_BODY "([^\\ \\n]*[^,;\?><()\\ \"\\.\\n])"
+#define BODY "([^\\ \\n\"]+)"
+#define END_BODY "([^\\ \\n\"]*[^,;\?><()\\ \"\\.\\n])"
#define URI_REGEX "("SCHEMES"://"END_BODY")" \
"|((mailto:)?"BODY"@"BODY"\\."END_BODY")"\
"|((www|ftp)\\."END_BODY")"
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]