aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLars Magne Ingebrigtsen <[email protected]>2010-09-02 01:02:03 +0000
committerKatsumi Yamaoka <[email protected]>2010-09-02 01:02:03 +0000
commitc6c815761c687a1401afe6e9f25fc9e44f601345 (patch)
tree5ede42a61d60e23d0c87181ae2125211f0726882
parent53080505af9e0641753909f057897b4203dd2269 (diff)
gnus-html.el (gnus-html-wash-tags): "A" is also used for links, just like "a", it seems like; (gnus-html-image-url-blocked-p): Take a parameter for blocked-images since it needs to be picked from the correct buffer.
-rw-r--r--lisp/gnus/ChangeLog5
-rw-r--r--lisp/gnus/gnus-html.el13
2 files changed, 12 insertions, 6 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog
index 176efebfb2..50ddf73a8b 100644
--- a/lisp/gnus/ChangeLog
+++ b/lisp/gnus/ChangeLog
@@ -1,5 +1,10 @@
2010-09-01 Lars Magne Ingebrigtsen <[email protected]>
+ * gnus-html.el (gnus-html-wash-tags): "A" is also used for links, just
+ like "a", it seems like.
+ (gnus-html-image-url-blocked-p): Take a parameter for blocked-images
+ since it needs to be picked from the correct buffer.
+
* nnwfm.el: Removed.
* nnlistserv.el: Removed.
diff --git a/lisp/gnus/gnus-html.el b/lisp/gnus/gnus-html.el
index 9acbfa3915..a78c617184 100644
--- a/lisp/gnus/gnus-html.el
+++ b/lisp/gnus/gnus-html.el
@@ -136,7 +136,7 @@ fit these criteria."
(delete-region start end)
(gnus-put-image image (gnus-string-or string "*")))))
;; Normal, external URL.
- (unless (gnus-html-image-url-blocked-p url)
+ (unless (gnus-html-image-url-blocked-p url gnus-blocked-images)
(let ((file (gnus-html-image-id url)))
(if (file-exists-p file)
;; It's already cached, so just insert it.
@@ -151,7 +151,8 @@ fit these criteria."
(point-marker))
images)))))))
;; Add a link.
- ((equal tag "a")
+ ((or (equal tag "a")
+ (equal tag "A"))
(when (string-match "href=\"\\([^\"]+\\)" parameters)
(setq url (match-string 1 parameters))
(gnus-message 8 "Fetching link URL %s" url)
@@ -284,10 +285,10 @@ fit these criteria."
(delete-file (nth 2 file)))))))
-(defun gnus-html-image-url-blocked-p (url)
+(defun gnus-html-image-url-blocked-p (url blocked-images)
"Find out if URL is blocked by `gnus-blocked-images'."
- (let ((ret (and gnus-blocked-images
- (string-match gnus-blocked-images url))))
+ (let ((ret (and blocked-images
+ (string-match blocked-images url))))
(when ret
(gnus-message 8 "Image URL %s is blocked by gnus-blocked-images regex %s" url gnus-blocked-images))
ret))
@@ -301,7 +302,7 @@ fit these criteria."
(save-match-data
(while (re-search-forward "<img.*src=[\"']\\([^\"']+\\)" nil t)
(let ((url (match-string 1)))
- (unless (gnus-html-image-url-blocked-p url)
+ (unless (gnus-html-image-url-blocked-p url blocked-images)
(unless (file-exists-p (gnus-html-image-id url))
(push url urls)
(push (gnus-html-image-id url) urls)