diff options
author | Marc Mutz <marc.mutz@kdab.com> | 2020-04-27 11:11:54 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@kdab.com> | 2020-04-30 07:49:40 +0200 |
commit | 2e41a466903852facc3f3f0100d04149b72b2409 (patch) | |
tree | 92a217f9bb7e7895a944392304b68b30181a3360 /src | |
parent | 68a20d69419671f28990052aca4c89a52ee78046 (diff) |
QTextCodecs: fix a few more ushort/uint -> QChar conversions
They leaked through since QChar(char) was explicit and therefore
QChar(char16_t) was the only viable constructor left once we made
all non-character-type QChar ctors explicit, too.
Change-Id: I6d774fc4b0d3b7eb480bdb93afd17c2ee9260b1c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/codecs/qisciicodec.cpp | 2 | ||||
-rw-r--r-- | src/corelib/codecs/qsimplecodec.cpp | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/corelib/codecs/qisciicodec.cpp b/src/corelib/codecs/qisciicodec.cpp index 9689818559..314f069dda 100644 --- a/src/corelib/codecs/qisciicodec.cpp +++ b/src/corelib/codecs/qisciicodec.cpp @@ -262,7 +262,7 @@ QString QIsciiCodec::convertToUnicode(const char* chars, int len, ConverterState const int base = codecs[idx].base; for (int i = 0; i < len; ++i) { - ushort ch = (uchar) chars[i]; + char16_t ch = (uchar) chars[i]; if (ch < 0xa0) *uc++ = ch; else { diff --git a/src/corelib/codecs/qsimplecodec.cpp b/src/corelib/codecs/qsimplecodec.cpp index 4e82620003..c78a2ecabd 100644 --- a/src/corelib/codecs/qsimplecodec.cpp +++ b/src/corelib/codecs/qsimplecodec.cpp @@ -48,7 +48,7 @@ static const struct { const char *mime; const char *aliases[7]; int mib; - quint16 values[128]; + char16_t values[128]; } unicodevalues[QSimpleTextCodec::numSimpleCodecs] = { // from RFC 1489, ftp://ftp.isi.edu/in-notes/rfc1489.txt { "KOI8-R", { "csKOI8R", nullptr }, 2084, |