Yes, they are correct.
You must delete your (unsigned char*) since you own a copy of the QByteArray buffer.

Regards