Regarding the last post...
(involving qdatastream << qbytearray )

From Qt Assistant, "Format of the QDataStream Operators"

QByteArray
If the byte array is null: 0xFFFFFFFF (quint32)
Otherwise: the array size (quint32) followed by the array bytes, i.e. size bytes


So, from what I see, QDataStream doesn't do whatever "comes to its mind".
It's simply doing what it's told...

What I need to do is simply eliminate the use of QByteArray from the structure or find a fast, elegant, way to chop those array size bytes ...

BR,
Pedro Doria Meunier