diff --git a/engine/src/flutter/impeller/entity/entity_pass.cc b/engine/src/flutter/impeller/entity/entity_pass.cc index bff88bb587..213b0af28e 100644 --- a/engine/src/flutter/impeller/entity/entity_pass.cc +++ b/engine/src/flutter/impeller/entity/entity_pass.cc @@ -333,8 +333,8 @@ bool EntityPass::Render(ContentContext& renderer, Rect::MakeSize(root_render_target.GetRenderTargetSize()), {.readonly = true}); - IterateAllEntities([lazy_glyph_atlas = - renderer.GetLazyGlyphAtlas()](const Entity& entity) { + const auto& lazy_glyph_atlas = renderer.GetLazyGlyphAtlas(); + IterateAllEntities([&lazy_glyph_atlas](const Entity& entity) { if (const auto& contents = entity.GetContents()) { contents->PopulateGlyphAtlas(lazy_glyph_atlas, entity.DeriveTextScale()); }