From fda48d7a6bfa6f0b6e00e66ffbd078df4ec53dbf Mon Sep 17 00:00:00 2001 From: Brian Gianforcaro Date: Wed, 15 Sep 2021 23:58:44 -0700 Subject: [PATCH] LibGfx: Use move to avoid unnecessary ref/unref of network device RefPtr Flagged by pvs-studio as a potential perf optimization. --- Userland/Libraries/LibGfx/Typeface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Userland/Libraries/LibGfx/Typeface.cpp b/Userland/Libraries/LibGfx/Typeface.cpp index 17fd08b266f..074745bdc35 100644 --- a/Userland/Libraries/LibGfx/Typeface.cpp +++ b/Userland/Libraries/LibGfx/Typeface.cpp @@ -35,7 +35,7 @@ void Typeface::add_bitmap_font(RefPtr font) void Typeface::set_ttf_font(RefPtr font) { - m_ttf_font = font; + m_ttf_font = move(font); } RefPtr Typeface::get_font(unsigned size) const