summaryrefslogtreecommitdiff
path: root/guix/store.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2016-06-19 21:29:43 +0200
committerLudovic Courtès <ludo@gnu.org>2016-06-20 00:52:53 +0200
commit95fa173ed12b832315d119d635b85813bb5317bd (patch)
treeb9140329245556285967235bc525d020d37c328d /guix/store.scm
parente0b47290a704c954d00d86e0c120fe44946f29f9 (diff)
store: 'register-path' no longer swallows 'system-error' exceptions.
* guix/store.scm (register-path): Do not catch 'system-error'.
Diffstat (limited to 'guix/store.scm')
-rw-r--r--guix/store.scm31
1 files changed, 13 insertions, 18 deletions
diff --git a/guix/store.scm b/guix/store.scm
index a64016611d..276684e2fb 100644
--- a/guix/store.scm
+++ b/guix/store.scm
@@ -1061,24 +1061,19 @@ Return #t on success.
Use with care as it directly modifies the store! This is primarily meant to
be used internally by the daemon's build hook."
;; Currently this is implemented by calling out to the fine C++ blob.
- (catch 'system-error
- (lambda ()
- (let ((pipe (apply open-pipe* OPEN_WRITE %guix-register-program
- `(,@(if prefix
- `("--prefix" ,prefix)
- '())
- ,@(if state-directory
- `("--state-directory" ,state-directory)
- '())))))
- (and pipe
- (begin
- (format pipe "~a~%~a~%~a~%"
- path (or deriver "") (length references))
- (for-each (cut format pipe "~a~%" <>) references)
- (zero? (close-pipe pipe))))))
- (lambda args
- ;; Failed to run %GUIX-REGISTER-PROGRAM.
- #f)))
+ (let ((pipe (apply open-pipe* OPEN_WRITE %guix-register-program
+ `(,@(if prefix
+ `("--prefix" ,prefix)
+ '())
+ ,@(if state-directory
+ `("--state-directory" ,state-directory)
+ '())))))
+ (and pipe
+ (begin
+ (format pipe "~a~%~a~%~a~%"
+ path (or deriver "") (length references))
+ (for-each (cut format pipe "~a~%" <>) references)
+ (zero? (close-pipe pipe))))))
;;;