mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-10 16:26:18 +02:00
Remove a redundant condition in DerivationGoal::tryLocalBuild()
This commit is contained in:
parent
44fd7a05b6
commit
0ca1a50132
1 changed files with 2 additions and 6 deletions
|
@ -679,13 +679,9 @@ void DerivationGoal::tryToBuild()
|
||||||
}
|
}
|
||||||
|
|
||||||
void DerivationGoal::tryLocalBuild() {
|
void DerivationGoal::tryLocalBuild() {
|
||||||
bool buildLocally = buildMode != bmNormal || parsedDrv->willBuildLocally(worker.store);
|
/* Make sure that we are allowed to start a build. */
|
||||||
|
|
||||||
/* Make sure that we are allowed to start a build. If this
|
|
||||||
derivation prefers to be done locally, do it even if
|
|
||||||
maxBuildJobs is 0. */
|
|
||||||
unsigned int curBuilds = worker.getNrLocalBuilds();
|
unsigned int curBuilds = worker.getNrLocalBuilds();
|
||||||
if (curBuilds >= settings.maxBuildJobs && !(buildLocally && curBuilds == 0)) {
|
if (curBuilds >= settings.maxBuildJobs) {
|
||||||
worker.waitForBuildSlot(shared_from_this());
|
worker.waitForBuildSlot(shared_from_this());
|
||||||
outputLocks.unlock();
|
outputLocks.unlock();
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in a new issue