]> git.eshelyaron.com Git - emacs.git/commitdiff
(cvs-retrieve-revision): Use decode-coding-inserted-region.
authorStefan Monnier <monnier@iro.umontreal.ca>
Wed, 14 Jun 2006 15:38:10 +0000 (15:38 +0000)
committerStefan Monnier <monnier@iro.umontreal.ca>
Wed, 14 Jun 2006 15:38:10 +0000 (15:38 +0000)
lisp/ChangeLog
lisp/pcvs.el

index 4db176fb5be219e66375919f156fb20233ee0833..f379f47fd6d6d5b559028604e936cde8c131b3bc 100644 (file)
@@ -1,3 +1,7 @@
+2006-06-14  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+       * pcvs.el (cvs-retrieve-revision): Use decode-coding-inserted-region.
+
 2006-06-13  Martin J. Reed  <mjreed@essex.ac.uk>  (tiny change)
 
        * net/ldap.el (ldap-ldapsearch-args): Default to SASL search.
@@ -14,7 +18,7 @@
 
 2006-06-11  Robert J. Chassell  <bob@rattlesnake.com>
 
-       * textmodes/page-ext.el (pages-directory-for-addresses): 
+       * textmodes/page-ext.el (pages-directory-for-addresses):
        Including `pages-directory-address-mode' in the function results
        in the message "Buffer in which pages were found is deleted".
 
@@ -92,8 +96,7 @@
 
 2006-06-06  Jesper Harder  <harder@phys.au.dk>
 
-       * ediff-diff.el (ediff-test-utility): Protect against
-       file-error.
+       * ediff-diff.el (ediff-test-utility): Protect against file-error.
 
 2006-06-06  Chong Yidong  <cyd@stupidchicken.com>
 
        cookies but no other non-empty fields.
        (org-set-tags): Allow groups of mutually exclusive tags.
        (org-cmp-time): Sort 24:21 before items without time.
-       (org-get-time-of-day): Fixed the interpretation of 12pm and 12am.
+       (org-get-time-of-day): Fix the interpretation of 12pm and 12am.
        (org-open-at-point): Require double colon also for numbers.
 
 2006-06-06  Kim F. Storm  <storm@cua.dk>
 
 2006-06-05  Kenichi Handa  <handa@m17n.org>
 
-       * international/mule.el (find-auto-coding): Handle
-       enable-character-translation in file header.
+       * international/mule.el (find-auto-coding):
+       Handle enable-character-translation in file header.
 
 2006-06-04  Kim F. Storm  <storm@cua.dk>
 
        as well as `coding'.
        (hack-local-variables): Likewise.
 
-       * international/mule.el (enable-character-translation): Put
-       permanent-local and safe-local-variable properties.
+       * international/mule.el (enable-character-translation):
+       Put permanent-local and safe-local-variable properties.
        (find-auto-coding): Handle char-trans: tag.
 
 2006-06-02  Juri Linkov  <juri@jurta.org>
index 5e322b9276af906c23d481de470a79abfbab46a2..89aeef53b8045099fc07c08196a967c56dfc20dc 100644 (file)
@@ -1723,16 +1723,22 @@ Signal an error if there is no backup file."
          (message "Retrieving revision %s..." rev)
          ;; Discard stderr output to work around the CVS+SSH+libc
          ;; problem when stdout and stderr are the same.
-         (let ((res (apply 'call-process cvs-program nil '(t nil) nil
-                           "-q" "update" "-p"
-                           ;; If `rev' is HEAD, don't pass it at all:
-                           ;; the default behavior is to get the head
-                           ;; of the current branch whereas "-r HEAD"
-                           ;; stupidly gives you the head of the trunk.
-                           (append (unless (equal rev "HEAD") (list "-r" rev))
-                                   (list file)))))
+         (let ((res
+                 (let ((coding-system-for-read 'binary))
+                   (apply 'call-process cvs-program nil '(t nil) nil
+                          "-q" "update" "-p"
+                          ;; If `rev' is HEAD, don't pass it at all:
+                          ;; the default behavior is to get the head
+                          ;; of the current branch whereas "-r HEAD"
+                          ;; stupidly gives you the head of the trunk.
+                          (append (unless (equal rev "HEAD") (list "-r" rev))
+                                  (list file))))))
            (when (and res (not (and (equal 0 res))))
              (error "Something went wrong retrieving revision %s: %s" rev res))
+            ;; Figure out the encoding used and decode the byte-sequence
+            ;; into a sequence of chars.
+            (decode-coding-inserted-region
+             (point-min) (point-max) file t nil nil t)
            (set-buffer-modified-p nil)
            (let ((buffer-file-name (expand-file-name file)))
              (after-find-file))