1
0
mirror of https://github.com/d47081/qBittorrent.git synced 2025-01-01 18:55:52 +00:00

Fix IPv6 endianness

This commit is contained in:
FranciscoPombal 2020-02-21 00:37:28 +00:00
parent 06ceac4cda
commit 9f045500d1

View File

@ -107,8 +107,8 @@ namespace
case QAbstractSocket::IPv6Protocol: {
const Q_IPV6ADDR ipv6 = addr.toIPv6Address();
QByteArray ret;
for (int i = (sizeof(ipv6.c) - 1); i >= 0; --i)
ret.append(static_cast<char>(ipv6.c[i]));
for (const quint8 i : ipv6.c)
ret.append(i);
return ret;
}