builder: fix cancellation context issue
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com> Upstream-commit: 2567dd9afc070428082aa1bec14ee037337dd5c4 Component: engine
This commit is contained in:
@ -137,7 +137,8 @@ func (b *Builder) Build(ctx context.Context, opt backend.BuildConfig) (*builder.
|
||||
b.jobs[buildID] = newBuildJob()
|
||||
}
|
||||
j := b.jobs[buildID]
|
||||
ctx, cancel := context.WithCancel(ctx)
|
||||
var cancel func()
|
||||
ctx, cancel = context.WithCancel(ctx)
|
||||
j.cancel = cancel
|
||||
b.mu.Unlock()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user