* gnus-art.el (article-verify-x-pgp-sig): Don't use
authorJesper Harder <harder@ifa.au.dk>
Mon, 7 Apr 2003 08:16:07 +0000 (08:16 +0000)
committerJesper Harder <harder@ifa.au.dk>
Mon, 7 Apr 2003 08:16:07 +0000 (08:16 +0000)
`insert-buffer', the docstring says "This function is meant for
the user to run interactively.  Don't call it from programs!"

* mm-extern.el (mm-extern-mail-server): do.

* mml1991.el (mml1991-mailcrypt-sign, mml1991-mailcrypt-sign)
(mml1991-gpg-sign, mml1991-gpg-encrypt, mml1991-pgg-sign)
(mml1991-pgg-encrypt): do.

* pgg.el (pgg-decrypt-region): do.

* mm-view.el (mm-view-pkcs7-decrypt): do.

* mml-smime.el (mml-smime-verify): do.

* mml.el (mml-insert-mime, mml-preview): do.

* mml2015.el (mml2015-gpg-decrypt-1, mml2015-gpg-sign)
(mml2015-gpg-encrypt, mml2015-pgg-clear-decrypt)
(mml2015-pgg-encrypt): do.

lisp/ChangeLog
lisp/gnus-art.el
lisp/mm-extern.el
lisp/mm-view.el
lisp/mml-smime.el
lisp/mml.el
lisp/mml1991.el
lisp/mml2015.el
lisp/pgg.el

index 34369a8..b2c566f 100644 (file)
@@ -1,3 +1,27 @@
+2003-04-07  Jesper Harder  <harder@ifa.au.dk>
+
+       * gnus-art.el (article-verify-x-pgp-sig): Don't use
+       `insert-buffer', the docstring says "This function is meant for
+       the user to run interactively.  Don't call it from programs!"
+
+       * mm-extern.el (mm-extern-mail-server): do.
+
+       * mml1991.el (mml1991-mailcrypt-sign, mml1991-mailcrypt-sign)
+       (mml1991-gpg-sign, mml1991-gpg-encrypt, mml1991-pgg-sign)
+       (mml1991-pgg-encrypt): do.
+
+       * pgg.el (pgg-decrypt-region): do.
+
+       * mm-view.el (mm-view-pkcs7-decrypt): do.
+
+       * mml-smime.el (mml-smime-verify): do.
+
+       * mml.el (mml-insert-mime, mml-preview): do.
+
+       * mml2015.el (mml2015-gpg-decrypt-1, mml2015-gpg-sign)
+       (mml2015-gpg-encrypt, mml2015-pgg-clear-decrypt)
+       (mml2015-pgg-encrypt): do.
+
 2003-04-06  Katsumi Yamaoka  <yamaoka@jpl.org>
 
        * mm-bodies.el (mm-decode-body): Silence XEmacs when compiling.
index 0c9887e..a8fcbc1 100644 (file)
@@ -3303,7 +3303,7 @@ If variable `gnus-use-long-file-name' is non-nil, it is
                   mml2015-use
                   (mml2015-clear-verify-function))
          (with-temp-buffer
-           (insert-buffer gnus-original-article-buffer)
+           (insert-buffer-substring gnus-original-article-buffer)
            (setq items (split-string sig))
            (message-narrow-to-head)
            (let ((inhibit-point-motion-hooks t)
index dfad89f..4a2b25c 100644 (file)
@@ -98,7 +98,7 @@
          (message-mail server subject)
          (message-goto-body)
          (delete-region (point) (point-max))
-         (insert-buffer buf)
+         (insert-buffer-substring buf)
          (message "Requesting external body...")
          (message-send-and-exit)
          (setq info "Request is sent.")
index 0c036f6..47daf7c 100644 (file)
@@ -559,7 +559,7 @@ map.")))
   t)
 
 (defun mm-view-pkcs7-decrypt (handle)
-  (insert-buffer (mm-handle-buffer handle))
+  (insert-buffer-substring (mm-handle-buffer handle))
   (goto-char (point-min))
   (insert "MIME-Version: 1.0\n")
   (mm-insert-headers "application/pkcs7-mime" "base64" "smime.p7m")
index 2eec919..5939b08 100644 (file)
 
 (defun mml-smime-verify (handle ctl)
   (with-temp-buffer
-    (insert-buffer (mm-handle-multipart-original-buffer ctl))
+    (insert-buffer-substring (mm-handle-multipart-original-buffer ctl))
     (goto-char (point-min))
     (insert (format "Content-Type: %s; " (mm-handle-media-type ctl)))
     (insert (format "protocol=\"%s\"; "
index 9729e6e..bbc908c 100644 (file)
@@ -738,7 +738,7 @@ If HANDLES is non-nil, use it instead reparsing the buffer."
        (mml-insert-mml-markup handle buffer textp)))
     (cond
      (mmlp
-      (insert-buffer buffer)
+      (insert-buffer-substring buffer)
       (goto-char (point-max))
       (insert "<#/mml>\n"))
      ((stringp (car handle))
@@ -1039,7 +1039,7 @@ If RAW, don't highlight the article."
                         (concat (if raw "*Raw MIME preview of "
                                   "*MIME preview of ") (buffer-name))))
       (erase-buffer)
-      (insert-buffer buf)
+      (insert-buffer-substring buf)
       (mml-preview-insert-mail-followup-to)
       (let ((message-deletable-headers (if (message-news-p)
                                           nil
index 63903d7..49419b5 100644 (file)
@@ -62,7 +62,7 @@
     (quoted-printable-decode-region (point-min) (point-max))
     (with-temp-buffer
       (setq signature (current-buffer))
-      (insert-buffer text)
+      (insert-buffer-substring text)
       (unless (mc-sign-generic (message-options-get 'message-sender)
                               nil nil nil nil)
        (unless (> (point-max) (point-min))
@@ -76,7 +76,7 @@
       (delete-region (point-min) (point-max))
       (if headers (insert headers))
       (insert "\n")
-      (insert-buffer signature)
+      (insert-buffer-substring signature)
       (goto-char (point-max)))))
 
 (defun mml1991-mailcrypt-encrypt (cont &optional sign)
     (mm-with-unibyte-current-buffer-mule4
       (with-temp-buffer
        (setq cipher (current-buffer))
-       (insert-buffer text)
+       (insert-buffer-substring text)
        (unless (mc-encrypt-generic
                 (or
                  (message-options-get 'message-recipients)
        ;;(insert "Content-Type: application/pgp-encrypted\n\n")
        ;;(insert "Version: 1\n\n")
        (insert "\n")
-       (insert-buffer cipher)
+       (insert-buffer-substring cipher)
        (goto-char (point-max))))))
 
 ;;; gpg wrapper
       (delete-region (point-min) (point-max))
       (if headers (insert headers))
       (insert "\n")
-      (insert-buffer signature)
+      (insert-buffer-substring signature)
       (goto-char (point-max)))))
 
 (defun mml1991-gpg-encrypt (cont &optional sign)
        ;;(insert "Content-Type: application/pgp-encrypted\n\n")
        ;;(insert "Version: 1\n\n")
        (insert "\n")
-       (insert-buffer cipher)
+       (insert-buffer-substring cipher)
        (goto-char (point-max))))))
 
 ;; pgg wrapper
       (pop-to-buffer pgg-errors-buffer)
       (error "Encrypt error"))
     (delete-region (point-min) (point-max))
-    (insert-buffer pgg-output-buffer)
+    (insert-buffer-substring pgg-output-buffer)
     (goto-char (point-min))
     (while (re-search-forward "\r+$" nil t)
       (replace-match "" t t))
     ;;(insert "Content-Type: application/pgp-encrypted\n\n")
     ;;(insert "Version: 1\n\n")
     (insert "\n")
-    (insert-buffer pgg-output-buffer)
+    (insert-buffer-substring pgg-output-buffer)
     t))
 
 ;;;###autoload
index 6f9880f..34007f1 100644 (file)
               (buffer-string)))
            (set-buffer cipher)
            (erase-buffer)
-           (insert-buffer plain)
+           (insert-buffer-substring plain)
            (goto-char (point-min))
            (while (search-forward "\r\n" nil t)
              (replace-match "\n" t t))))
       (goto-char (point-max))
       (insert (format "\n--%s\n" boundary))
       (insert "Content-Type: application/pgp-signature\n\n")
-      (insert-buffer signature)
+      (insert-buffer-substring signature)
       (goto-char (point-max))
       (insert (format "--%s--\n" boundary))
       (goto-char (point-max)))))
        (insert "Version: 1\n\n")
        (insert (format "--%s\n" boundary))
        (insert "Content-Type: application/octet-stream\n\n")
-       (insert-buffer cipher)
+       (insert-buffer-substring cipher)
        (goto-char (point-max))
        (insert (format "--%s--\n" boundary))
        (goto-char (point-max))))))
             (buffer-string))))
        (progn
          (erase-buffer)
-         (insert-buffer pgg-output-buffer)
+         (insert-buffer-substring pgg-output-buffer)
          (goto-char (point-min))
          (while (search-forward "\r\n" nil t)
            (replace-match "\n" t t))
     (goto-char (point-max))
     (insert (format "\n--%s\n" boundary))
     (insert "Content-Type: application/pgp-signature\n\n")
-    (insert-buffer pgg-output-buffer)
+    (insert-buffer-substring pgg-output-buffer)
     (goto-char (point-max))
     (insert (format "--%s--\n" boundary))
     (goto-char (point-max))))
     (insert "Version: 1\n\n")
     (insert (format "--%s\n" boundary))
     (insert "Content-Type: application/octet-stream\n\n")
-    (insert-buffer pgg-output-buffer)
+    (insert-buffer-substring pgg-output-buffer)
     (goto-char (point-max))
     (insert (format "--%s--\n" boundary))
     (goto-char (point-max))))
index 407e5c1..f69298c 100644 (file)
@@ -179,7 +179,7 @@ the region."
   (interactive "r")
   (let* ((buf (current-buffer))
         (packet (cdr (assq 1 (with-temp-buffer
-                               (insert-buffer buf)
+                               (insert-buffer-substring buf)
                                (pgg-decode-armor-region
                                 (point-min) (point-max))))))
         (key (cdr (assq 'key-identifier packet)))