summaryrefslogtreecommitdiffstats
path: root/src/corelib/text
diff options
context:
space:
mode:
Diffstat (limited to 'src/corelib/text')
-rw-r--r--src/corelib/text/qbytearray.cpp2
-rw-r--r--src/corelib/text/qlocale.cpp4
2 files changed, 3 insertions, 3 deletions
diff --git a/src/corelib/text/qbytearray.cpp b/src/corelib/text/qbytearray.cpp
index 1eb5162fb1..521b970137 100644
--- a/src/corelib/text/qbytearray.cpp
+++ b/src/corelib/text/qbytearray.cpp
@@ -636,7 +636,7 @@ QByteArray qUncompress(const uchar* data, qsizetype nbytes)
size_t expectedSize = size_t((data[0] << 24) | (data[1] << 16) |
(data[2] << 8) | (data[3] ));
size_t len = qMax(expectedSize, 1ul);
- const ulong maxPossibleSize = MaxAllocSize - sizeof(QByteArray::Data);
+ const size_t maxPossibleSize = MaxAllocSize - sizeof(QByteArray::Data);
if (Q_UNLIKELY(len >= maxPossibleSize)) {
// QByteArray does not support that huge size anyway.
return invalidCompressedData();
diff --git a/src/corelib/text/qlocale.cpp b/src/corelib/text/qlocale.cpp
index 152570bc84..c20e117778 100644
--- a/src/corelib/text/qlocale.cpp
+++ b/src/corelib/text/qlocale.cpp
@@ -3992,8 +3992,8 @@ QString QLocale::currencySymbol(QLocale::CurrencySymbolFormat format) const
return d->m_data->currencyDisplayName().getListEntry(currency_display_name_data, 0);
case CurrencyIsoCode: {
const char *code = d->m_data->m_currency_iso_code;
- if (int len = qstrnlen(code, 3))
- return QString::fromLatin1(code, len);
+ if (auto len = qstrnlen(code, 3))
+ return QString::fromLatin1(code, int(len));
break;
}
}