diff --git a/src/corelib/text/qstringconverter.cpp b/src/corelib/text/qstringconverter.cpp index f961431dfd..84f293ae5f 100644 --- a/src/corelib/text/qstringconverter.cpp +++ b/src/corelib/text/qstringconverter.cpp @@ -852,7 +852,7 @@ int QUtf8::compareUtf8(const char *utf8, qsizetype u8len, const QChar *utf16, qs int QUtf8::compareUtf8(const char *utf8, qsizetype u8len, QLatin1String s) { - uint uc1; + uint uc1 = QChar::Null; auto src1 = reinterpret_cast(utf8); auto end1 = src1 + u8len; auto src2 = reinterpret_cast(s.latin1());