diff options
author | Brian Gianforcaro <bgianf@serenityos.org> | 2021-09-15 23:58:44 -0700 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-09-16 17:17:13 +0200 |
commit | fda48d7a6bfa6f0b6e00e66ffbd078df4ec53dbf (patch) | |
tree | 84e3c76f02fc41b2f18a5d143b609f4524bd1beb | |
parent | f327f543997cf8079572ed3fab745baa3e5d95f3 (diff) | |
download | serenity-fda48d7a6bfa6f0b6e00e66ffbd078df4ec53dbf.zip |
LibGfx: Use move to avoid unnecessary ref/unref of network device RefPtr
Flagged by pvs-studio as a potential perf optimization.
-rw-r--r-- | Userland/Libraries/LibGfx/Typeface.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/Libraries/LibGfx/Typeface.cpp b/Userland/Libraries/LibGfx/Typeface.cpp index 17fd08b266..074745bdc3 100644 --- a/Userland/Libraries/LibGfx/Typeface.cpp +++ b/Userland/Libraries/LibGfx/Typeface.cpp @@ -35,7 +35,7 @@ void Typeface::add_bitmap_font(RefPtr<BitmapFont> font) void Typeface::set_ttf_font(RefPtr<TTF::Font> font) { - m_ttf_font = font; + m_ttf_font = move(font); } RefPtr<Font> Typeface::get_font(unsigned size) const |