(mmcooked-entity-content): New alias for `mmbuffer-entity-content'.
authormorioka <morioka>
Tue, 30 Jun 1998 12:18:34 +0000 (12:18 +0000)
committermorioka <morioka>
Tue, 30 Jun 1998 12:18:34 +0000 (12:18 +0000)
(mmcooked-write-entity-content): New function.

mmcooked.el

index 8d4e0df..ad3653a 100644 (file)
 
 (defun mmcooked-cooked-p () t)
 
+(defalias 'mmcooked-entity-content     'mmbuffer-entity-content)
+
+(defun mmcooked-write-entity-content (entity filename)
+  (save-excursion
+    (set-buffer (mime-entity-buffer-internal entity))
+    (let ((encoding (or (mime-entity-encoding entity) "7bit")))
+      (if (member encoding '("7bit" "8bit" "binary"))
+         (write-region (mime-entity-body-start-internal entity)
+                       (mime-entity-body-end-internal entity) filename)
+       (mime-write-decoded-region (mime-entity-body-start-internal entity)
+                                  (mime-entity-body-end-internal entity)
+                                  filename encoding)
+       ))))
+
 
 ;;; @ end
 ;;;