[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] scratch/backports-25.2 8fd0223 06/46: Make mail-extract-ad
From: |
Noam Postavsky |
Subject: |
[Emacs-diffs] scratch/backports-25.2 8fd0223 06/46: Make mail-extract-address-components return the user name more |
Date: |
Sun, 2 Oct 2016 14:04:47 +0000 (UTC) |
branch: scratch/backports-25.2
commit 8fd022375e4ca06ea59284371c9694f9a278db78
Author: Lars Ingebrigtsen <address@hidden>
Commit: Noam Postavsky <address@hidden>
Make mail-extract-address-components return the user name more
* lisp/mail/mail-extr.el (mail-extract-address-components):
Return the name even if it's the same as the mailbox name (if
`mail-extr-ignore-single-names' isn't set) (bug#22594).
(cherry picked from commit 8b50ae8b2284b5652c2843a9d0d076f4f657be28)
---
lisp/mail/mail-extr.el | 39 ++++++++++++++++++++-------------------
1 file changed, 20 insertions(+), 19 deletions(-)
diff --git a/lisp/mail/mail-extr.el b/lisp/mail/mail-extr.el
index 44a082c..4f3e71d 100644
--- a/lisp/mail/mail-extr.el
+++ b/lisp/mail/mail-extr.el
@@ -1406,25 +1406,26 @@ consing a string.)"
(insert (upcase mi) ". ")))
;; Nuke name if it is the same as mailbox name.
- (let ((buffer-length (- (point-max) (point-min)))
- (i 0)
- (names-match-flag t))
- (when (and (> buffer-length 0)
- (eq buffer-length (- mbox-end mbox-beg)))
- (goto-char (point-max))
- (insert-buffer-substring canonicalization-buffer
- mbox-beg mbox-end)
- (while (and names-match-flag
- (< i buffer-length))
- (or (eq (downcase (char-after (+ i (point-min))))
- (downcase
- (char-after (+ i buffer-length (point-min)))))
- (setq names-match-flag nil))
- (setq i (1+ i)))
- (delete-region (+ (point-min) buffer-length) (point-max))
- (and names-match-flag
- mail-extr-ignore-realname-equals-mailbox-name
- (narrow-to-region (point) (point)))))
+ (when mail-extr-ignore-single-names
+ (let ((buffer-length (- (point-max) (point-min)))
+ (i 0)
+ (names-match-flag t))
+ (when (and (> buffer-length 0)
+ (eq buffer-length (- mbox-end mbox-beg)))
+ (goto-char (point-max))
+ (insert-buffer-substring canonicalization-buffer
+ mbox-beg mbox-end)
+ (while (and names-match-flag
+ (< i buffer-length))
+ (or (eq (downcase (char-after (+ i (point-min))))
+ (downcase
+ (char-after (+ i buffer-length (point-min)))))
+ (setq names-match-flag nil))
+ (setq i (1+ i)))
+ (delete-region (+ (point-min) buffer-length) (point-max))
+ (and names-match-flag
+ mail-extr-ignore-realname-equals-mailbox-name
+ (narrow-to-region (point) (point))))))
;; Nuke name if it's just one word.
(goto-char (point-min))
- [Emacs-diffs] scratch/backports-25.2 e1e768e 01/46: Default web pages to right-to-left, (continued)
- [Emacs-diffs] scratch/backports-25.2 e1e768e 01/46: Default web pages to right-to-left, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 b16e6c3 09/46: Require that the buffer that we're trying to patch exist, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 e2e25ae 20/46: Make <div> in <li> not insert extra newlines, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 77c3f7f 24/46: Make `q' etc work in image mode again, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 d7de0c4 25/46: smtpmail would say it's done before it is, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 f65b1a3 27/46: Don't consider colons to be paragraphs starting chars in strings, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 d95942f 29/46: Clean up custom-buffer-create code slightly, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 18f1ab7 30/46: Have describe-variable output multi-line values better, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 f24a305 26/46: Make `undo' of `C-x r t' put point where it should be, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 33b69a1 37/46: Warning fix in jit-lock-mode, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 8fd0223 06/46: Make mail-extract-address-components return the user name more,
Noam Postavsky <=
- [Emacs-diffs] scratch/backports-25.2 7826f1f 32/46: Make ibuffer not break on newline-embedded buffer names, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 4af6945 39/46: Add `size-indication-mode' to the menu on `mouse-1' "Top", Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 5afea13 33/46: Rename "Directory Search" menu to "Servers", Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 d6f5232 34/46: Remove ": ?" from the read-face-name prompt, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 3713acd 36/46: Cancel the eldoc timer when switching off eldoc mode, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 90262cc 40/46: Allow `global-set-key' to bind keys under the `M-o' map, Noam Postavsky, 2016/10/02
- [Emacs-diffs] scratch/backports-25.2 c9443ca 38/46: Make describe-variable look up the variable in the current buffer, Noam Postavsky, 2016/10/02