Setting m_payloadSize is already handled by qvariant2qobject and it is of type qint64 not int
This commit is contained in:
parent
c22c670fee
commit
f91b9e9951
1 changed files with 0 additions and 1 deletions
|
@ -147,7 +147,6 @@ bool NetworkPacket::unserialize(const QByteArray& a, NetworkPacket* np)
|
|||
auto variant = parser.toVariant().toMap();
|
||||
qvariant2qobject(variant, np);
|
||||
|
||||
np->m_payloadSize = variant[QStringLiteral("payloadSize")].toInt(); //Will return 0 if was not present, which is ok
|
||||
if (np->m_payloadSize == -1) {
|
||||
np->m_payloadSize = np->get<int>(QStringLiteral("size"), -1);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue