diff options
| author | Richard M. Stallman | 1995-09-25 18:40:24 +0000 |
|---|---|---|
| committer | Richard M. Stallman | 1995-09-25 18:40:24 +0000 |
| commit | 5d2e6ef5ca1a84decc72ea6c513c40a7b9d9f798 (patch) | |
| tree | 5fcebd87c5a26a7b4c004f203954f2b841561cfb | |
| parent | 42499979a3e60634f7ac7299169e4384ad5a9da2 (diff) | |
| download | emacs-5d2e6ef5ca1a84decc72ea6c513c40a7b9d9f798.tar.gz emacs-5d2e6ef5ca1a84decc72ea6c513c40a7b9d9f798.zip | |
(undigestify-rmail-message): Scan back as far as start
of message, to find end of digest.
| -rw-r--r-- | lisp/mail/undigest.el | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lisp/mail/undigest.el b/lisp/mail/undigest.el index b80a5f4a48b..83ea58b3b63 100644 --- a/lisp/mail/undigest.el +++ b/lisp/mail/undigest.el | |||
| @@ -55,10 +55,12 @@ Leaves original message, deleted, before the undigestified messages." | |||
| 55 | (point-max)) | 55 | (point-max)) |
| 56 | (let* ((fill-prefix "") | 56 | (let* ((fill-prefix "") |
| 57 | (case-fold-search t) | 57 | (case-fold-search t) |
| 58 | start | ||
| 58 | (digest-name | 59 | (digest-name |
| 59 | (mail-strip-quoted-names | 60 | (mail-strip-quoted-names |
| 60 | (or (save-restriction | 61 | (or (save-restriction |
| 61 | (search-forward "\n\n") | 62 | (search-forward "\n\n") |
| 63 | (setq start (point)) | ||
| 62 | (narrow-to-region (point-min) (point)) | 64 | (narrow-to-region (point-min) (point)) |
| 63 | (goto-char (point-max)) | 65 | (goto-char (point-max)) |
| 64 | (or (mail-fetch-field "Reply-To") | 66 | (or (mail-fetch-field "Reply-To") |
| @@ -69,11 +71,10 @@ Leaves original message, deleted, before the undigestified messages." | |||
| 69 | (save-excursion | 71 | (save-excursion |
| 70 | (goto-char (point-max)) | 72 | (goto-char (point-max)) |
| 71 | (skip-chars-backward " \t\n") | 73 | (skip-chars-backward " \t\n") |
| 72 | (let ((count 10) found) | 74 | (let (found) |
| 73 | ;; compensate for broken un*x digestifiers. Sigh Sigh. | 75 | ;; compensate for broken un*x digestifiers. Sigh Sigh. |
| 74 | (while (and (> count 0) (not found)) | 76 | (while (and (> (point) start) (not found)) |
| 75 | (forward-line -1) | 77 | (forward-line -1) |
| 76 | (setq count (1- count)) | ||
| 77 | (if (looking-at (concat "End of.*Digest.*\n" | 78 | (if (looking-at (concat "End of.*Digest.*\n" |
| 78 | (regexp-quote "*********") "*" | 79 | (regexp-quote "*********") "*" |
| 79 | "\\(\n------*\\)*")) | 80 | "\\(\n------*\\)*")) |