mirror of
https://github.com/moby/buildkit.git
synced 2026-08-07 00:00:52 +00:00
Calling marshal changes the internal state of the op, for example addCap() helper adds capability constraints. These can race with same map being read by another Marshal call. Locking the Marshal function itself also makes sure that the cache is not recomputed in this case. Signed-off-by: Tonis Tiigi <tonistiigi@gmail.com>