1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-26 20:01:15 +02:00

add call to checkInterrupt in a bunch of places

This brings back the old behaviour. We check for interrupts in places
that may iterate over wide directories.
This commit is contained in:
siddhantCodes 2024-06-04 19:35:40 +05:30
parent 1623249745
commit 8f1a26667e
13 changed files with 29 additions and 3 deletions

View file

@ -133,6 +133,7 @@ SourceAccessor::DirEntries PosixSourceAccessor::readDirectory(const CanonPath &
assertNoSymlinks(path);
DirEntries res;
for (auto & entry : std::filesystem::directory_iterator{makeAbsPath(path)}) {
checkInterrupt();
auto type = [&]() -> std::optional<Type> {
std::filesystem::file_type nativeType;
try {