summaryrefslogtreecommitdiff
path: root/lisp
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2010-03-17 23:13:45 -0700
committerGlenn Morris <rgm@gnu.org>2010-03-17 23:13:45 -0700
commit88b8d18e9219635a84c3a3668927ebb7ba32e432 (patch)
treea7e02d35ceb405130a3d3bcccc6b55779052acfa /lisp
parentfa61430f7d80d823c84215f2788f5bf7120b2bb2 (diff)
downloademacs-88b8d18e9219635a84c3a3668927ebb7ba32e432.tar.gz
Remove supercite.el's need for sendmail.el.
* mail/supercite.el: Don't require sendmail. (mh-in-header-p): Declare rather than using with-no-warnings. (sc-no-blank-line-or-header): Use rfc822-goto-eoh rather than mail-header-end. Don't bind mysterious variable `kill-lines-magic'.
Diffstat (limited to 'lisp')
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/mail/supercite.el27
2 files changed, 20 insertions, 12 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 407d700c289..5dab389647d 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,5 +1,10 @@
2010-03-18 Glenn Morris <rgm@gnu.org>
+ * mail/supercite.el: Don't require sendmail.
+ (mh-in-header-p): Declare rather than using with-no-warnings.
+ (sc-no-blank-line-or-header): Use rfc822-goto-eoh rather than
+ mail-header-end. Don't bind mysterious variable `kill-lines-magic'.
+
* calendar/cal-french.el: Convert to utf-8.
* files.el (interpreter-mode-alist): Use emacs-lisp-mode for
diff --git a/lisp/mail/supercite.el b/lisp/mail/supercite.el
index f3636c6504f..9144be89e96 100644
--- a/lisp/mail/supercite.el
+++ b/lisp/mail/supercite.el
@@ -34,7 +34,6 @@
(require 'regi)
-(require 'sendmail) ;; For mail-header-end.
;; start user configuration variables
;; vvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvvv
@@ -1484,18 +1483,22 @@ non-nil."
"Does nothing. Use this instead of nil to get a blank header."
())
-(defun sc-no-blank-line-or-header()
+(declare-function mh-in-header-p "mh-utils" ())
+
+(defun sc-no-blank-line-or-header ()
"Similar to `sc-no-header' except it removes the preceding blank line."
- (if (not (bobp))
- (if (and (eolp)
- (progn (forward-line -1)
- (or (= (point) (mail-header-end))
- (and (eq major-mode 'mh-letter-mode)
- (with-no-warnings
- (mh-in-header-p))))))
- (progn (forward-line)
- (let ((kill-lines-magic t))
- (kill-line))))))
+ (and (not (bobp))
+ (eolp)
+ (progn (forward-line -1)
+ (or (= (point)
+ (save-excursion
+ (rfc822-goto-eoh)
+ (line-beginning-position 2)))
+ (and (eq major-mode 'mh-letter-mode)
+ (mh-in-header-p))))
+ (progn
+ (forward-line)
+ (kill-line))))
(defun sc-header-on-said ()
"\"On <date>, <from> said:\" unless: