From 5e3cd3e292611a9c640e9f2b5809e1b1793ba625 Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Wed, 21 Dec 2022 16:47:26 +0100 Subject: [PATCH] Fix FilteringInputAccessor::pathExists() Co-authored-by: Robert Hensing --- src/libexpr/primops/filterPath.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/libexpr/primops/filterPath.cc b/src/libexpr/primops/filterPath.cc index c2db5b029..b4325c6d8 100644 --- a/src/libexpr/primops/filterPath.cc +++ b/src/libexpr/primops/filterPath.cc @@ -29,8 +29,7 @@ struct FilteringInputAccessor : InputAccessor bool pathExists(const CanonPath & path) override { - checkAccess(path); - return next->pathExists(prefix + path); + return isAllowed(path) && next->pathExists(prefix + path); } Stat lstat(const CanonPath & path) override