diff options
| author | Stefan Monnier | 2000-11-06 13:21:09 +0000 |
|---|---|---|
| committer | Stefan Monnier | 2000-11-06 13:21:09 +0000 |
| commit | 4d2806e27adf13ae54e8013d393d09e51d8aaefa (patch) | |
| tree | 131e2dc6546aed0e6b7e27d528ff415b7506b6f1 | |
| parent | bb21621841b9dacca9017664b7f94818fd98ba0a (diff) | |
| download | emacs-4d2806e27adf13ae54e8013d393d09e51d8aaefa.tar.gz emacs-4d2806e27adf13ae54e8013d393d09e51d8aaefa.zip | |
(vc-insert-file): Don't assume byte==char.
| -rw-r--r-- | lisp/ChangeLog | 6 | ||||
| -rw-r--r-- | lisp/vc-hooks.el | 17 |
2 files changed, 11 insertions, 12 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 486210e4194..db1d13ffb31 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -20,6 +20,8 @@ | |||
| 20 | 20 | ||
| 21 | 2000-11-06 Stefan Monnier <monnier@cs.yale.edu> | 21 | 2000-11-06 Stefan Monnier <monnier@cs.yale.edu> |
| 22 | 22 | ||
| 23 | * vc-hooks.el (vc-insert-file): Don't assume byte==char. | ||
| 24 | |||
| 23 | * pcvs.el (cvs-mode-marked): New arg `noquery'. | 25 | * pcvs.el (cvs-mode-marked): New arg `noquery'. |
| 24 | Prompt user for a file rather than raising an error. | 26 | Prompt user for a file rather than raising an error. |
| 25 | (cvs-enabledp): Fix call to cvs-mode-marked. | 27 | (cvs-enabledp): Fix call to cvs-mode-marked. |
| @@ -37,8 +39,8 @@ | |||
| 37 | (cvs-status-get-tags): Fix regexp. | 39 | (cvs-status-get-tags): Fix regexp. |
| 38 | (cvs-status-trees, cvs-status-cvstrees): | 40 | (cvs-status-trees, cvs-status-cvstrees): |
| 39 | Combine after change hooks and don't sit-for. | 41 | Combine after change hooks and don't sit-for. |
| 40 | (cvs-tree-use-jisx0208): Renamed from cvs-tree-dstr-2byte-ready. | 42 | (cvs-tree-use-jisx0208): Rename from cvs-tree-dstr-2byte-ready. |
| 41 | (cvs-tree-char-*): Renamed from cvs-tree-dstr-char-*. | 43 | (cvs-tree-char-*): Rename from cvs-tree-dstr-char-*. |
| 42 | Use make-char rather than hard-coded cryptic data. | 44 | Use make-char rather than hard-coded cryptic data. |
| 43 | (cvs-status-cvstrees): Convert the buffer to multibyte if necessary. | 45 | (cvs-status-cvstrees): Convert the buffer to multibyte if necessary. |
| 44 | 46 | ||
diff --git a/lisp/vc-hooks.el b/lisp/vc-hooks.el index 7af6c735c97..a91f76740d3 100644 --- a/lisp/vc-hooks.el +++ b/lisp/vc-hooks.el | |||
| @@ -5,7 +5,7 @@ | |||
| 5 | ;; Author: FSF (see vc.el for full credits) | 5 | ;; Author: FSF (see vc.el for full credits) |
| 6 | ;; Maintainer: Andre Spiegel <spiegel@gnu.org> | 6 | ;; Maintainer: Andre Spiegel <spiegel@gnu.org> |
| 7 | 7 | ||
| 8 | ;; $Id: vc-hooks.el,v 1.126 2000/10/27 13:26:18 spiegel Exp $ | 8 | ;; $Id: vc-hooks.el,v 1.127 2000/11/04 18:24:50 spiegel Exp $ |
| 9 | 9 | ||
| 10 | ;; This file is part of GNU Emacs. | 10 | ;; This file is part of GNU Emacs. |
| 11 | 11 | ||
| @@ -215,15 +215,12 @@ exists and its contents were successfully inserted." | |||
| 215 | (if (not limit) | 215 | (if (not limit) |
| 216 | (insert-file-contents file) | 216 | (insert-file-contents file) |
| 217 | (if (not blocksize) (setq blocksize 8192)) | 217 | (if (not blocksize) (setq blocksize 8192)) |
| 218 | (let (found s) | 218 | (let ((filepos 0)) |
| 219 | (while (not found) | 219 | (while |
| 220 | (setq s (buffer-size)) | 220 | (and (< 0 (cadr (insert-file-contents |
| 221 | (goto-char (1+ s)) | 221 | file nil filepos (incf filepos blocksize)))) |
| 222 | (setq found | 222 | (progn (beginning-of-line) |
| 223 | (or (zerop (cadr (insert-file-contents | 223 | (not (re-search-forward limit nil 'move))))))) |
| 224 | file nil s (+ s blocksize)))) | ||
| 225 | (progn (beginning-of-line) | ||
| 226 | (re-search-forward limit nil t))))))) | ||
| 227 | (set-buffer-modified-p nil) | 224 | (set-buffer-modified-p nil) |
| 228 | t)) | 225 | t)) |
| 229 | 226 | ||