hugolib: Revert to using Page as the render chan type

Changing it to PageOutput was a mistake. You may think that the increased parallelism should be a good thing.

But not so much with the increased lock contention and more complex concurrency model.
This commit is contained in:
Bjørn Erik Pedersen 2017-03-07 09:55:17 +01:00
parent e5200ddaa4
commit 03122e51fa
2 changed files with 38 additions and 35 deletions

View file

@ -25,9 +25,11 @@ type PageOutput struct {
outputType output.Type
}
func newPageOutput(p *Page, outputType output.Type) *PageOutput {
func newPageOutput(p *Page, createCopy bool, outputType output.Type) *PageOutput {
// TODO(bep) output avoid copy of first?
p = p.copy()
if createCopy {
p = p.copy()
}
return &PageOutput{Page: p, outputType: outputType}
}