mirror of
https://github.com/NixOS/nix.git
synced 2025-12-12 20:11:03 +01:00
addPath(): Restore catching InvalidPathError
This commit is contained in:
parent
c080c4ca56
commit
02055c5a48
1 changed files with 4 additions and 1 deletions
|
|
@ -2815,7 +2815,10 @@ static void addPath(
|
|||
auto rewrites = state.realiseContext(context);
|
||||
path = {path.accessor, CanonPath(rewriteStrings(path.path.abs(), rewrites))};
|
||||
auto [storePath, subPath] = state.store->toStorePath(path.path.abs());
|
||||
refs = state.store->queryPathInfo(storePath)->references;
|
||||
try {
|
||||
refs = state.store->queryPathInfo(storePath)->references;
|
||||
} catch (Error &) { // FIXME: should be InvalidPathError
|
||||
}
|
||||
}
|
||||
|
||||
std::unique_ptr<PathFilter> filter;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue