summaryrefslogtreecommitdiff
path: root/guix/download.scm
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2018-12-20 18:39:04 +0100
committerLudovic Courtès <ludo@gnu.org>2018-12-20 18:39:04 +0100
commit86974d8a9247cbeb938b5202f23ccca8d9ed627d (patch)
tree7bd498ccf672aced617aa24a830ec4164268c03f /guix/download.scm
parent03a45a40227d97ccafeb49c4eb0fc7539f4d2127 (diff)
parent9012d226fa46229a84e49a42c9b6d287105dfddf (diff)
downloadguix-patches-86974d8a9247cbeb938b5202f23ccca8d9ed627d.tar
guix-patches-86974d8a9247cbeb938b5202f23ccca8d9ed627d.tar.gz
Merge branch 'master' into core-updates
Diffstat (limited to 'guix/download.scm')
-rw-r--r--guix/download.scm12
1 files changed, 3 insertions, 9 deletions
diff --git a/guix/download.scm b/guix/download.scm
index a7f51b1999..25eaefcffa 100644
--- a/guix/download.scm
+++ b/guix/download.scm
@@ -411,17 +411,11 @@
(object->string %content-addressed-mirrors)))
(define built-in-builders*
- (let ((cache (make-weak-key-hash-table)))
+ (let ((proc (store-lift built-in-builders)))
(lambda ()
"Return, as a monadic value, the list of built-in builders supported by
-the daemon."
- (lambda (store)
- ;; Memoize the result to avoid repeated RPCs.
- (values (or (hashq-ref cache store)
- (let ((result (built-in-builders store)))
- (hashq-set! cache store result)
- result))
- store)))))
+the daemon; cache the return value."
+ (mcached (proc) built-in-builders))))
(define* (built-in-download file-name url
#:key system hash-algo hash