emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] /srv/bzr/emacs/trunk r105062: * mh-xface.el (mh-face-to-pn


From: Bill Wohler
Subject: [Emacs-diffs] /srv/bzr/emacs/trunk r105062: * mh-xface.el (mh-face-to-png, mh-uncompface)
Date: Sat, 09 Jul 2011 13:19:10 -0700
User-agent: Bazaar (2.3.1)

------------------------------------------------------------
revno: 105062
committer: Bill Wohler <address@hidden>
branch nick: trunk
timestamp: Sat 2011-07-09 13:19:10 -0700
message:
  * mh-xface.el (mh-face-to-png, mh-uncompface)
  (mh-picon-file-contents): Only call set-buffer-multibyte if it exists,
  which it doesn't in XEmacs.
modified:
  lisp/mh-e/mh-xface.el
=== modified file 'lisp/mh-e/mh-xface.el'
--- a/lisp/mh-e/mh-xface.el     2011-01-26 08:36:39 +0000
+++ b/lisp/mh-e/mh-xface.el     2011-07-09 20:19:10 +0000
@@ -125,7 +125,8 @@
 (defun mh-face-to-png (data)
   "Convert base64 encoded DATA to png image."
   (with-temp-buffer
-    (set-buffer-multibyte nil)
+    (if (fboundp 'set-buffer-multibyte)
+        (set-buffer-multibyte nil))
     (insert data)
     (ignore-errors (base64-decode-region (point-min) (point-max)))
     (buffer-string)))
@@ -133,7 +134,8 @@
 (defun mh-uncompface (data)
   "Run DATA through `uncompface' to generate bitmap."
   (with-temp-buffer
-    (set-buffer-multibyte nil)
+    (if (fboundp 'set-buffer-multibyte)
+        (set-buffer-multibyte nil))
     (insert data)
     (when (and mh-uncompface-executable
                (equal (call-process-region (point-min) (point-max)
@@ -271,7 +273,8 @@
 elements of the list are nil."
   (if (stringp file)
       (with-temp-buffer
-        (set-buffer-multibyte nil)
+        (if (fboundp 'set-buffer-multibyte)
+            (set-buffer-multibyte nil))
         (let ((type (and (string-match ".*\\.\\(...\\)$" file)
                          (intern (match-string 1 file)))))
           (insert-file-contents-literally file)


reply via email to

[Prev in Thread] Current Thread [Next in Thread]