Linux sandbox: Don't barf on invalid paths

This is useful when we're using a diverted store (e.g. "--store
local?root=/tmp/nix") in conjunction with a statically-linked sh from
the host store (e.g. "sandbox-paths =/bin/sh=/nix/store/.../bin/busybox").
This commit is contained in:
Eelco Dolstra 2017-05-15 17:26:20 +02:00
parent 2b761d5f50
commit b30f5784d0
No known key found for this signature in database
GPG key ID: 8170B4726D7198DE

View file

@ -1774,6 +1774,7 @@ void DerivationGoal::startBuilder()
try {
if (worker.store.isInStore(i.second.source))
worker.store.computeFSClosure(worker.store.toStorePath(i.second.source), closure);
} catch (InvalidPath & e) {
} catch (Error & e) {
throw Error(format("while processing build-sandbox-paths: %s") % e.what());
}