changeset 110107:ffa0ce354f9d

gnus-html.el: prefix log messages with function name
author Katsumi Yamaoka <yamaoka@jpl.org>
date Thu, 02 Sep 2010 01:18:45 +0000
parents 8e1063b66037
children 5412f2e311ef
files lisp/gnus/ChangeLog lisp/gnus/gnus-html.el
diffstat 2 files changed, 15 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/gnus/ChangeLog	Thu Sep 02 01:14:38 2010 +0000
+++ b/lisp/gnus/ChangeLog	Thu Sep 02 01:18:45 2010 +0000
@@ -1,3 +1,9 @@
+2010-09-01  Teodor Zlatanov  <tzz@lifelogs.com>
+
+	* gnus-html.el (gnus-html-wash-tags)
+	(gnus-html-schedule-image-fetching, gnus-html-image-url-blocked-p):
+	Better logging.
+
 2010-09-01  Lars Magne Ingebrigtsen  <larsi@gnus.org>
 
 	* gnus-html.el (gnus-html-wash-tags): Check the value of
--- a/lisp/gnus/gnus-html.el	Thu Sep 02 01:14:38 2010 +0000
+++ b/lisp/gnus/gnus-html.el	Thu Sep 02 01:18:45 2010 +0000
@@ -119,7 +119,7 @@
        ((equal tag "img_alt")
         (when (string-match "src=\"\\([^\"]+\\)" parameters)
 	  (setq url (match-string 1 parameters))
-          (gnus-message 8 "Fetching image URL %s" url)
+          (gnus-message 8 "gnus-html-wash-tags: fetching image URL %s" url)
 	  (if (string-match "^cid:\\(.*\\)" url)
 	      ;; URLs with cid: have their content stashed in other
 	      ;; parts of the MIME structure, so just insert them
@@ -160,7 +160,7 @@
 	    (equal tag "A"))
 	(when (string-match "href=\"\\([^\"]+\\)" parameters)
 	  (setq url (match-string 1 parameters))
-          (gnus-message 8 "Fetching link URL %s" url)
+          (gnus-message 8 "gnus-html-wash-tags: fetching link URL %s" url)
 	  (gnus-article-add-button start end
 				   'browse-url url
 				   url)
@@ -186,7 +186,8 @@
       (gnus-html-schedule-image-fetching (current-buffer) (nreverse images)))))
 
 (defun gnus-html-schedule-image-fetching (buffer images)
-  (gnus-message 8 "Scheduling image fetching in buffer %s, images %s" buffer images)
+  (gnus-message 8 "gnus-html-schedule-image-fetching: buffer %s, images %s"
+                buffer images)
   (let* ((url (caar images))
 	 (process (start-process
 		   "images" nil "curl"
@@ -294,8 +295,11 @@
 "Find out if URL is blocked by BLOCKED-IMAGES."
   (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 blocked-images))
+    (if ret
+        (gnus-message 8 "gnus-html-image-url-blocked-p: %s blocked by regex %s"
+                      url blocked-images)
+      (gnus-message 9 "gnus-html-image-url-blocked-p: %s passes regex %s"
+                    url blocked-images))
     ret))
 
 ;;;###autoload