Changes committed gnus/lisp (ChangeLog gnus-registry.el gnus-util.el)
"Ted Zlatanov" <[email protected]>
| Newsgroups | gmane.emacs.gnus.commits |
|---|---|
| Message-ID | <[email protected]> |
Modified: ChangeLog gnus-registry.el gnus-util.el * gnus-util.el (gnus-extract-address-component-name) (gnus-extract-address-component-email): Convenience functions around `gnus-extract-address-components'. * gnus-registry.el (gnus-registry-split-fancy-with-parent): Use `gnus-extract-address-component-email' to fix bug of comparing full sender name to `user-mail-address'. Index: ChangeLog diff -u gnus/lisp/ChangeLog:7.1849 gnus/lisp/ChangeLog:7.1850 --- ChangeLog:7.1849 Mon May 5 23:36:33 2008 +++ ChangeLog Wed May 7 17:41:32 2008 @@ -1,3 +1,13 @@ +2008-05-07 Teodor Zlatanov <[email protected]> + + * gnus-util.el (gnus-extract-address-component-name) + (gnus-extract-address-component-email): Convenience functions around + `gnus-extract-address-components'. + + * gnus-registry.el (gnus-registry-split-fancy-with-parent): Use + `gnus-extract-address-component-email' to fix bug of comparing full + sender name to `user-mail-address'. + 2008-05-05 Teodor Zlatanov <[email protected]> * gnus-registry.el (gnus-registry-grep-in-list): Fix logic, use Index: gnus-registry.el diff -u gnus/lisp/gnus-registry.el:7.60 gnus/lisp/gnus-registry.el:7.61 --- gnus-registry.el:7.60 Mon May 5 23:36:32 2008 +++ gnus-registry.el Wed May 7 17:41:32 2008 @@ -525,7 +525,8 @@ ;; else: there were no matches, now try the extra tracking by sender ((and (gnus-registry-track-sender-p) sender - (not (equal sender user-mail-address))) + (not (equal (gnus-extract-address-component-email sender) + user-mail-address))) (maphash (lambda (key value) (let ((this-sender (cdr Index: gnus-util.el diff -u gnus/lisp/gnus-util.el:7.78 gnus/lisp/gnus-util.el:7.79 --- gnus-util.el:7.78 Thu Apr 24 06:19:20 2008 +++ gnus-util.el Wed May 7 17:41:32 2008 @@ -195,6 +195,15 @@ (match-end 0))))) (list (if (string= name "") nil name) (or address from)))) +(defun gnus-extract-address-component-name (from) + "Extract name from a From header. +Uses `gnus-extract-address-components'." + (nth 0 (gnus-extract-address-components from))) + +(defun gnus-extract-address-component-email (from) + "Extract e-mail address from a From header. +Uses `gnus-extract-address-components'." + (nth 1 (gnus-extract-address-components from))) (defun gnus-fetch-field (field) "Return the value of the header FIELD of current article."