1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-02-04 06:31:13 -08:00

Adjust jka-compr to recent Tramp changes.

* lisp/jka-compr.el (jka-compr-write-region):
Two new args LOCKNAME and MUSTBENEW.
This commit is contained in:
Paul Eggert 2017-08-12 08:52:25 -07:00
parent a685d9d759
commit bbf52c142a

View file

@ -252,7 +252,8 @@ There should be no more than seven characters after the final `/'."
"This routine will return the name of a new file."
(make-temp-file jka-compr-temp-name-template))
(defun jka-compr-write-region (start end file &optional append visit)
(defun jka-compr-write-region (start end file &optional
append visit lockname mustbenew)
(let* ((filename (expand-file-name file))
(visit-file (if (stringp visit) (expand-file-name visit) filename))
(info (jka-compr-get-compression-info visit-file))
@ -334,7 +335,8 @@ There should be no more than seven characters after the final `/'."
(jka-compr-run-real-handler 'write-region
(list (point-min) (point-max)
filename
(and append can-append) 'dont))
(and append can-append) 'dont
lockname mustbenew))
(erase-buffer)) )
(delete-file temp-file)
@ -365,7 +367,8 @@ There should be no more than seven characters after the final `/'."
nil)
(jka-compr-run-real-handler 'write-region
(list start end filename append visit)))))
(list start end filename append visit
lockname mustbenew)))))
(defun jka-compr-insert-file-contents (file &optional visit beg end replace)