projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
422f15d
)
shr: strip leading whitespace when expanding URLs
author
Andreas Schwab
<schwab@linux-m68k.org>
Fri, 24 Apr 2015 15:18:55 +0000
(17:18 +0200)
committer
Andreas Schwab
<schwab@linux-m68k.org>
Fri, 24 Apr 2015 15:19:31 +0000
(17:19 +0200)
* lisp/net/shr.el (shr-expand-url): Strip leading whitespace from URL.
lisp/net/shr.el
patch
|
blob
|
history
diff --git
a/lisp/net/shr.el
b/lisp/net/shr.el
index 9d88d1ff4419b74fa7ed81dbdf823470d39d963f..454332e55d0f9e679cae4302eb6bdadadff62515 100644
(file)
--- a/
lisp/net/shr.el
+++ b/
lisp/net/shr.el
@@
-709,6
+709,9
@@
size, and full-buffer size."
shr-base))
(when (zerop (length url))
(setq url nil))
+ ;; Strip leading whitespace
+ (and url (string-match "\\`\\s-+" url)
+ (setq url (substring url (match-end 0))))
(cond ((or (not url)
(not base)
(string-match "\\`[a-z]*:" url))