Merge pull request #331576 from LeSuisse/env-vars-not-world-readable

stdenv: make sure the `env-vars` file created is not world readable
This commit is contained in:
Martin Weinelt
2024-08-05 00:33:37 +02:00
committed by GitHub
+1 -1
View File
@@ -1044,7 +1044,7 @@ substituteAllInPlace() {
# the environment used for building.
dumpVars() {
if [ "${noDumpEnvVars:-0}" != 1 ]; then
export 2>/dev/null >| "$NIX_BUILD_TOP/env-vars" || true
install -m 0600 <(export 2>/dev/null) "$NIX_BUILD_TOP/env-vars" || true
fi
}