(mime-method-to-verify-application/pgp-signature): Don't use temporary
authormorioka <morioka>
Sat, 14 Mar 1998 13:37:00 +0000 (13:37 +0000)
committermorioka <morioka>
Sat, 14 Mar 1998 13:37:00 +0000 (13:37 +0000)
buffer for signed entity.

mime-pgp.el

index ab24633..5819e83 100644 (file)
@@ -189,28 +189,15 @@ It should be ISO 639 2 letter language code such as en, ja, ...")
         (orig-file (make-temp-name basename))
         (sig-file (concat orig-file ".sig"))
         )
-    (save-excursion
-      (let ((p-min (mime-entity-info-point-min oinfo))
-           (p-max (mime-entity-info-point-max oinfo))
-           )
-       (set-buffer (get-buffer-create mime-temp-buffer-name))
-       (insert-buffer-substring raw-buf p-min p-max)
-       )
-      (goto-char (point-min))
-      (while (re-search-forward "\n" nil t)
-       (replace-match "\r\n")
-       )
-      (write-region-as-binary (point-min)(point-max) orig-file)
-      (kill-buffer (current-buffer))
-      )
+    (write-region-as-binary (mime-entity-info-point-min oinfo)
+                           (mime-entity-info-point-max oinfo)
+                           orig-file)
     (save-excursion (mime-show-echo-buffer))
-    (let ((p-min (save-excursion
-                  (goto-char start)
-                  (and (search-forward "\n\n")
-                       (match-end 0))
-                  )))
-      (mime-write-decoded-region p-min end sig-file encoding)
-      )
+    (mime-write-decoded-region (save-excursion
+                                (goto-char start)
+                                (and (search-forward "\n\n")
+                                     (match-end 0))
+                                ) end sig-file encoding)
     (or (mime-pgp-check-signature mime-echo-buffer-name orig-file)
        (let (pgp-id)
          (save-excursion