mirror of
https://github.com/moby/buildkit.git
synced 2026-06-30 19:57:39 +00:00
control: make sure sending nil cache options does not panic
Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>
This commit is contained in:
@@ -376,6 +376,9 @@ func (c *Controller) Solve(ctx context.Context, req *controlapi.SolveRequest) (*
|
||||
atomic.AddInt64(&c.buildCount, 1)
|
||||
defer atomic.AddInt64(&c.buildCount, -1)
|
||||
|
||||
if req.Cache == nil {
|
||||
req.Cache = &controlapi.CacheOptions{} // make sure cache options are initialized
|
||||
}
|
||||
translateLegacySolveRequest(req)
|
||||
|
||||
defer func() {
|
||||
|
||||
Reference in New Issue
Block a user