From cd81b3e2facd82cac6f61c00d6a05a1fcff6688e Mon Sep 17 00:00:00 2001 From: Nico Weber Date: Sat, 29 Apr 2023 22:19:27 -0400 Subject: [PATCH] TestICCProfile: Don't capture sRGB by value No behavior change. --- Tests/LibGfx/TestICCProfile.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tests/LibGfx/TestICCProfile.cpp b/Tests/LibGfx/TestICCProfile.cpp index 4af7ffa61a..5d70d04332 100644 --- a/Tests/LibGfx/TestICCProfile.cpp +++ b/Tests/LibGfx/TestICCProfile.cpp @@ -108,7 +108,7 @@ TEST_CASE(to_pcs) EXPECT_EQ(sRGB_curve.evaluate(0.f), 0.f); EXPECT_EQ(sRGB_curve.evaluate(1.f), 1.f); - auto xyz_from_sRGB = [sRGB](u8 r, u8 g, u8 b) { + auto xyz_from_sRGB = [&sRGB](u8 r, u8 g, u8 b) { u8 rgb[3] = { r, g, b }; return MUST(sRGB->to_pcs(rgb)); }; @@ -157,7 +157,7 @@ TEST_CASE(to_pcs) TEST_CASE(to_lab) { auto sRGB = MUST(Gfx::ICC::sRGB()); - auto lab_from_sRGB = [sRGB](u8 r, u8 g, u8 b) { + auto lab_from_sRGB = [&sRGB](u8 r, u8 g, u8 b) { u8 rgb[3] = { r, g, b }; return MUST(sRGB->to_lab(rgb)); };