aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Magne Ingebrigtsen2015-01-10 16:41:49 +0100
committerLars Magne Ingebrigtsen2015-01-10 16:41:49 +0100
commit1fd00738641f54cef63a4bdc389e8eaf94643577 (patch)
tree13dfdf8c4b59db387c6b5857f597c2fae09ba7d4
parent790ca72b3e5790bd8af6f76831ac0c3dde01288e (diff)
downloademacs-1fd00738641f54cef63a4bdc389e8eaf94643577.tar.gz
emacs-1fd00738641f54cef63a4bdc389e8eaf94643577.zip
(eww): Don't interpret "org/foo" as an URL.
-rw-r--r--lisp/ChangeLog1
-rw-r--r--lisp/net/eww.el2
2 files changed, 2 insertions, 1 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 9bfcd504199..ac0701f8619 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -4,6 +4,7 @@
4 as plain URLs, even if they have spaces in them (bug#19556). 4 as plain URLs, even if they have spaces in them (bug#19556).
5 (eww): Also interpret things like "en.wikipedia.org/wiki/Free 5 (eww): Also interpret things like "en.wikipedia.org/wiki/Free
6 software" as an URL. 6 software" as an URL.
7 (eww): Don't interpret "org/foo" as an URL.
7 8
82015-01-10 Daniel Colascione <dancol@dancol.org> 92015-01-10 Daniel Colascione <dancol@dancol.org>
9 10
diff --git a/lisp/net/eww.el b/lisp/net/eww.el
index 8278e3cc1ba..46b07605000 100644
--- a/lisp/net/eww.el
+++ b/lisp/net/eww.el
@@ -258,7 +258,7 @@ word(s) will be searched for via `eww-search-prefix'."
258 (if (or (string-match "\\`https?:" url) 258 (if (or (string-match "\\`https?:" url)
259 ;; Also try to match "naked" URLs like 259 ;; Also try to match "naked" URLs like
260 ;; en.wikipedia.org/wiki/Free software 260 ;; en.wikipedia.org/wiki/Free software
261 (string-match "\\`[a-z._]+/" url) 261 (string-match "\\`[A-Za-z_]+\\.[A-Za-z._]+/" url)
262 (and (= (length (split-string url)) 1) 262 (and (= (length (split-string url)) 1)
263 (or (and (not (string-match-p "\\`[\"\'].*[\"\']\\'" url)) 263 (or (and (not (string-match-p "\\`[\"\'].*[\"\']\\'" url))
264 (> (length (split-string url "[.:]")) 1)) 264 (> (length (split-string url "[.:]")) 1))