1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-06-25 14:51:16 +02:00

Merge pull request #13068 from DeterminateSystems/fix-warning

DerivationBuilder: Fix compiler warning
This commit is contained in:
John Ericson 2025-04-23 14:10:55 -04:00 committed by GitHub
commit 714662e675
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1127,7 +1127,7 @@ void DerivationBuilderImpl::startBuilder()
if (needsHashRewrite() && pathExists(homeDir)) if (needsHashRewrite() && pathExists(homeDir))
throw Error("home directory '%1%' exists; please remove it to assure purity of builds without sandboxing", homeDir); throw Error("home directory '%1%' exists; please remove it to assure purity of builds without sandboxing", homeDir);
if (useChroot && settings.preBuildHook != "" && dynamic_cast<const Derivation *>(&drv)) { if (useChroot && settings.preBuildHook != "") {
printMsg(lvlChatty, "executing pre-build hook '%1%'", settings.preBuildHook); printMsg(lvlChatty, "executing pre-build hook '%1%'", settings.preBuildHook);
auto args = useChroot ? Strings({store.printStorePath(drvPath), chrootRootDir}) : auto args = useChroot ? Strings({store.printStorePath(drvPath), chrootRootDir}) :
Strings({ store.printStorePath(drvPath) }); Strings({ store.printStorePath(drvPath) });