+1999-04-13 Hirokazu FUKUI <fukui@atesoft.advantest.co.jp>
+
+ * mime-pgp.el (mime-add-application/pgp-keys): Call
+ `buffer-substring' in entity's buffer.
+
1999-04-15 Katsumi Yamaoka <yamaoka@jpl.org>
* mime-mc.el (mime-mc-insert-public-key, mime-mc-encrypt-region,
(defun mime-add-application/pgp-keys (entity situation)
(let* ((start (mime-entity-point-min entity))
(end (mime-entity-point-max entity))
- (entity-number (mime-raw-point-to-entity-number start))
- (new-name (format "%s-%s" (buffer-name) entity-number))
+ (entity-number (mime-raw-point-to-entity-number start entity))
+ (new-name (format "%s-%s"
+ (buffer-name (mime-entity-buffer entity))
+ entity-number))
(encoding (cdr (assq 'encoding situation)))
str)
- (setq str (buffer-substring start end))
+ (setq str (save-excursion
+ (set-buffer (mime-entity-buffer entity))
+ (buffer-substring start end)))
(switch-to-buffer new-name)
(setq buffer-read-only nil)
(erase-buffer)