projects
/
emacs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
29fffbd
)
* lisp/net/shr.el (shr-expand-url): Also strip trailing
author
Andreas Schwab
<schwab@linux-m68k.org>
Thu, 23 Dec 2021 18:06:13 +0000
(19:06 +0100)
committer
Andreas Schwab
<schwab@linux-m68k.org>
Thu, 23 Dec 2021 18:07:49 +0000
(19:07 +0100)
whitespace.
lisp/net/shr.el
patch
|
blob
|
history
diff --git
a/lisp/net/shr.el
b/lisp/net/shr.el
index 48590fd675a37f17fcfcab98aea296376a08a682..4a22091d59bcdb6003bb81d8ddf3e2fc269caa2a 100644
(file)
--- a/
lisp/net/shr.el
+++ b/
lisp/net/shr.el
@@
-941,9
+941,11
@@
size, and full-buffer size."
shr-base))
(when (zerop (length url))
(setq url nil))
- ;; Strip leading whitespace
+ ;; Strip leading
/trailing
whitespace
(and url (string-match "\\`\\s-+" url)
(setq url (substring url (match-end 0))))
+ (and url (string-match "\\s-+\\'" url)
+ (setq url (substring url 0 (match-beginning 0))))
(cond ((zerop (length url))
(nth 3 base))
((or (not base)