Skip to content
Snippets Groups Projects
Commit 294233ed authored by Daniel Barlow's avatar Daniel Barlow
Browse files

Patch from Nikodemus Siivola:

 1. Ensures that filename gets pushed to *temporary-files* even if
    download bombs.

 2. Doesn't try to delete non-existent temp-files, which can now happen due
    to no 1.
parent 52c83250
No related branches found
No related tags found
No related merge requests found
......@@ -269,8 +269,8 @@ an immediate concern
(loop for p in packages
unless (probe-file p)
do (let ((tmp (temp-file-name p)))
(download p tmp)
(pushnew tmp *temporary-files*)
(download p tmp)
(setf p tmp))
end
do (format t "Installing ~A in ~A,~A~%" p source system)
......@@ -289,7 +289,8 @@ an immediate concern
(let ((*temporary-files* nil))
(unwind-protect
(run)
(dolist (l *temporary-files*) (delete-file l))))
(dolist (l *temporary-files*)
(when (probe-file l) (delete-file l)))))
(error (c)
(princ "Install failed due to error:") (terpri)
(princ c) (terpri)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment