diff options
-rw-r--r-- | src/libstore/build.cc | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libstore/build.cc b/src/libstore/build.cc index c13ea6d23..77e968ddd 100644 --- a/src/libstore/build.cc +++ b/src/libstore/build.cc @@ -1793,6 +1793,9 @@ void DerivationGoal::startBuilder() if (chdir(tmpDir.c_str()) == -1) throw SysError(format("changing into `%1%'") % tmpDir); + /* Close all other file descriptors. */ + closeMostFDs(set<int>()); + #ifdef CAN_DO_LINUX32_BUILDS /* Change the personality to 32-bit if we're doing an i686-linux build on an x86_64-linux machine. */ |