X-Git-Url: http://www.git.cypherpunks.ru/?a=blobdiff_plain;f=ifchange.go;h=d4588107b6fc3e4ae1b9ac02cf4102799d60bdcb;hb=1acd70630cf8aabeed4f63cac167ca7dc7f274b3;hp=a7fe9472372548644cff5c06867bc79b5160ebd9;hpb=b2eef1c806af5802089517b8c86abc65edfe574d;p=goredo.git diff --git a/ifchange.go b/ifchange.go index a7fe947..d458810 100644 --- a/ifchange.go +++ b/ifchange.go @@ -92,6 +92,11 @@ func buildDependants(tgts []string) map[string]struct{} { return nil } + levelOrig := Level + defer func() { + Level = levelOrig + }() + Level = 1 trace(CDebug, "building %d alwayses: %v", len(seen), seen) errs := make(chan error, len(seen)) for tgt, _ := range seen { @@ -118,11 +123,6 @@ func buildDependants(tgts []string) map[string]struct{} { if len(queueSrc) == 0 { return seen } - levelOrig := Level - defer func() { - Level = levelOrig - }() - Level = 1 RebuildDeps: trace(CDebug, "checking %d dependant targets: %v", len(queueSrc), queueSrc)