From 0302e6f16802cc324d313f3b678a0fe526f9482b Mon Sep 17 00:00:00 2001 From: Patric Stout Date: Tue, 30 May 2023 21:17:30 +0200 Subject: [PATCH] Codechange: initialize all values of ICURun on construction (#10892) --- src/gfx_layout_icu.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gfx_layout_icu.cpp b/src/gfx_layout_icu.cpp index 730df125bd..1311030a64 100644 --- a/src/gfx_layout_icu.cpp +++ b/src/gfx_layout_icu.cpp @@ -46,7 +46,7 @@ public: std::vector advance; ///< The advance (width) of the glyphs. Valid after Shape() is called. std::vector glyph_to_char; ///< The mapping from glyphs to characters. Valid after Shape() is called. std::vector positions; ///< The positions of the glyphs. Valid after Shape() is called. - int total_advance; ///< The total advance of the run. Valid after Shape() is called. + int total_advance = 0; ///< The total advance of the run. Valid after Shape() is called. ICURun(int start, int length, UBiDiLevel level, UScriptCode script = USCRIPT_UNKNOWN, Font *font = nullptr) : start(start), length(length), level(level), script(script), font(font) {}