HCoop
/
jackhill
/
guix
/
guix.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d1f33ba
)
utils: 'with-atomic-file-output' closes the port upon exception.
author
Ludovic Courtès
<ludo@gnu.org>
Mon, 13 Jun 2016 16:00:29 +0000
(18:00 +0200)
committer
Ludovic Courtès
<ludo@gnu.org>
Mon, 13 Jun 2016 16:05:54 +0000
(18:05 +0200)
Previously it could have left the file descriptor open.
* guix/utils.scm (with-atomic-file-output): Call 'close-port' in handler.
guix/utils.scm
patch
|
blob
|
blame
|
history
diff --git
a/guix/utils.scm
b/guix/utils.scm
index
18d913c
..
2d8bfd8
100644
(file)
--- a/
guix/utils.scm
+++ b/
guix/utils.scm
@@
-630,7
+630,8
@@
output port, and PROC's result is returned."
(rename-file template file)
result))
(lambda (key . args)
- (false-if-exception (delete-file template))))))
+ (false-if-exception (delete-file template))
+ (close-port out)))))
(define (cache-directory)
"Return the cache directory for Guix, by default ~/.cache/guix."