[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#4451: 23.1; EOL problems with vc-diff and cygwin
From: |
Stefan Monnier |
Subject: |
bug#4451: 23.1; EOL problems with vc-diff and cygwin |
Date: |
Thu, 17 Sep 2009 12:35:37 -0400 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/23.1.50 (gnu/linux) |
I think the best solution is to change vc-coding-system-for-diff so that
when it takes the coding system from (with-current-buffer buf
buffer-file-coding-system), it ignores the EOL part of that
coding system.
Does the patch below help?
Stefan
=== modified file 'lisp/vc.el'
--- lisp/vc.el 2009-09-14 15:39:41 +0000
+++ lisp/vc.el 2009-09-17 16:35:00 +0000
@@ -1470,7 +1470,11 @@
;; use the buffer's coding system
(let ((buf (find-buffer-visiting file)))
(when buf (with-current-buffer buf
- buffer-file-coding-system)))
+ (if buffer-file-coding-system
+ ;; Don't inherit the EOL part of the coding-system,
+ ;; because some diff tools may choose to use
+ ;; another one.
+ (coding-system-base buffer-file-coding-system)))))
;; otherwise, try to find one based on the file name
(car (find-operation-coding-system 'insert-file-contents file))
;; and a final fallback
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Reiner Steib, 2009/09/16
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Eli Zaretskii, 2009/09/16
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Reiner Steib, 2009/09/17
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Reiner Steib, 2009/09/18
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Reiner Steib, 2009/09/24
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Stefan Monnier, 2009/09/25
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Eli Zaretskii, 2009/09/25
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Reiner Steib, 2009/09/26
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Eli Zaretskii, 2009/09/26
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Stefan Monnier, 2009/09/26
- bug#4451: 23.1; EOL problems with vc-diff and cygwin, Eli Zaretskii, 2009/09/27