Commit b3985039 authored by Eli Zaretskii's avatar Eli Zaretskii
Browse files

(archive-maybe-copy): Fix the way directories in the archive are created

in archive-tmpdir.
parent 67e53305
......@@ -800,17 +800,13 @@ using `make-temp-file', and the generated name is returned."
(or (and archive-subfile-mode (aref archive-subfile-mode 0))
(make-directory archive-tmpdir t)
;; If ARCHIVE includes leading directories, make sure they
;; exist under archive-tmpdir.
(let ((arch-dir (file-name-directory archive)))
(if arch-dir
(make-directory (concat
(file-name-as-directory archive-tmpdir)
(setq archive-local-name
(archive-unique-fname archive-name archive-tmpdir))
;; Maked sure all the leading directories in
;; archive-local-name exist under archive-tmpdir, so that
;; the directory structure recorded in the archive is
;; reconstructed in the temporary directory.
(make-directory (file-name-directory archive-local-name) t)
(write-region start (point-max) archive-local-name nil 'nomessage))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment