* lisp/gnus/mm-bodies.el (mm-decode-body): Ditto.
* lisp/gnus/mm-decode.el (mm-tmp-directory)
(mm-valid-image-format-p): Remove compat code.
* lisp/gnus/mm-url.el (mm-url-insert-file-contents): Remove
"Connection" "Close" workaround for older Emacsen.
(condition-case nil
(let ((fill-prefix (when quote (concat quote " ")))
(fill-column (eval fill-flowed-display-column))
- filladapt-mode
adaptive-fill-mode)
(fill-region (point-at-bol)
(min (1+ (point-at-eol))
(inhibit-point-motion-hooks t)
(marks (gnus-dissect-cited-text))
(adaptive-fill-mode nil)
- (filladapt-mode nil)
(fill-column (if width (prefix-numeric-value width) fill-column)))
(save-restriction
(while (cdr marks)
(defun message-send-mail-function ()
"Return suitable value for the variable `message-send-mail-function'."
(cond ((and (require 'sendmail)
+ (boundp 'sendmail-program)
sendmail-program
(executable-find sendmail-program))
'message-send-mail-with-sendmail)
((and (locate-library "smtpmail")
+ (boundp 'smtpmail-default-smtp-server)
smtpmail-default-smtp-server)
'message-smtpmail-send-it)
((locate-library "mailclient")
(or (not (eq coding-system 'ascii))
(setq coding-system mail-parse-charset)))
(decode-coding-region (point-min) (point-max) coding-system))
- (setq buffer-file-coding-system
- (if (boundp 'last-coding-system-used)
- (symbol-value 'last-coding-system-used)
- coding-system))))))
+ (setq buffer-file-coding-system last-coding-system-used)))))
(defun mm-decode-string (string charset)
"Decode STRING with CHARSET."
:type '(repeat regexp) ;; See `mm-preferred-alternative-precedence'.
:group 'mime-display)
-(defcustom mm-tmp-directory
- (if (fboundp 'temp-directory)
- (temp-directory)
- (if (boundp 'temporary-file-directory)
- temporary-file-directory
- "/tmp/"))
+(defcustom mm-tmp-directory temporary-file-directory
"Where mm will store its temporary files."
:type 'directory
:group 'mime-display)
(defun mm-valid-image-format-p (format)
"Say whether FORMAT can be displayed natively by Emacs."
- (and (fboundp 'image-type-available-p)
- (display-graphic-p)
+ (and (display-graphic-p)
(image-type-available-p format)))
(defun mm-valid-and-fit-image-p (format handle)
(defun mm-shr (handle)
;; Require since we bind its variables.
(require 'shr)
- (let ((shr-width (if (and (boundp 'shr-use-fonts)
- shr-use-fonts)
+ (let ((shr-width (if shr-use-fonts
nil
fill-column))
(shr-content-function (lambda (id)
(insert-file-contents (substring url (1- (match-end 0))))
(mm-url-insert-file-contents-external url))
(goto-char (point-min))
- (if (fboundp 'url-generic-parse-url)
- (setq url-current-object
- (url-generic-parse-url url)))
+ (setq url-current-object (url-generic-parse-url url))
(list url (buffer-size)))
(mm-url-load-url)
(let ((name buffer-file-name)
- (url-request-extra-headers
- ;; ISTM setting a Connection header was a workaround for
- ;; older versions of url included with w3, but it does more
- ;; harm than good with the one shipped with Emacs. --ansel
- (if (not (and (boundp 'url-version)
- (equal url-version "Emacs")))
- (list (cons "Connection" "Close"))))
result)
(setq result (url-insert-file-contents url))
(save-excursion
(while (re-search-forward "\r 1000\r ?" nil t)
(replace-match "")))
(setq buffer-file-name name)
- (if (and (fboundp 'url-generic-parse-url)
- (listp result))
- (setq url-current-object (url-generic-parse-url
- (car result))))
+ (when (listp result)
+ (setq url-current-object
+ (url-generic-parse-url (car result))))
result)))
;;;###autoload
((= char ? ) "+")
((memq char mm-url-unreserved-chars) (char-to-string char))
(t (upcase (format "%%%02x" char)))))
- (encode-coding-string chunk
- (if (fboundp 'find-coding-systems-string)
- (car (find-coding-systems-string chunk))
- buffer-file-coding-system))
+ (encode-coding-string chunk (car (find-coding-systems-string chunk)))
"")))
(defun mm-url-encode-www-form-urlencoded (pairs)