1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2024-11-24 07:20:37 +00:00

* lisp/tar-mode.el (tar--extract, tar-extract): Avoid disabling undo

in extracted buffers.

Fixes: debbugs:18344
This commit is contained in:
Glenn Morris 2014-08-28 15:18:24 -04:00
parent 74910c5d07
commit 6539a7e2a2
2 changed files with 10 additions and 4 deletions

View File

@ -1,3 +1,8 @@
2014-08-28 Glenn Morris <rgm@gnu.org>
* tar-mode.el (tar--extract, tar-extract):
Avoid permanently disabling undo in extracted buffers. (Bug#18344)
2014-08-27 Michael Albinus <michael.albinus@gmx.de>
* emacs-lisp/authors.el (authors-aliases): Addition.

View File

@ -800,8 +800,6 @@ tar-file's buffer."
tarname
")"))
(buffer (generate-new-buffer bufname)))
(with-current-buffer buffer
(setq buffer-undo-list t))
(with-current-buffer tar-data-buffer
(let (coding)
(narrow-to-region start end)
@ -829,7 +827,11 @@ tar-file's buffer."
(with-current-buffer buffer
(set-buffer-multibyte nil)))
(widen)
(decode-coding-region start end coding buffer)))
(with-current-buffer buffer
(setq buffer-undo-list t))
(decode-coding-region start end coding buffer)
(with-current-buffer buffer
(setq buffer-undo-list nil))))
buffer))
(defun tar-extract (&optional other-window-p)
@ -869,7 +871,6 @@ tar-file's buffer."
(with-current-buffer tar-buffer
default-directory))
(set-buffer-modified-p nil)
(setq buffer-undo-list t)
(normal-mode) ; pick a mode.
(set (make-local-variable 'tar-superior-buffer) tar-buffer)
(set (make-local-variable 'tar-superior-descriptor) descriptor)