Here's the background.
I'm serialising a midi buffer and sending it as a UPD datagram from a Mac to a Linux machine. To serialize the midibuffer I am copying the data from the MidiBuffer's Array<uint8> data member into a MemoryBlock using copyFrom() like so:
data.copyFrom((void *) midiMessages->data.getRawDataPointer(), getMidiDataOffset(), midiMessages->data.size() * sizeof(uint8));
then deserialising like so:
buffer.data = Array<uint8>(this->header.midiData, this->header.midiDataSize);
This works on the mac internally. It works sending from a mac to a mac.
But mac to linux gives me garbage on the linux end. Midi notes are not parsed or recognized.
Sending the same Datagram message from linux back to the mac deserialises fine though.
This is leading me to believe that the serialisation is ok, and that something about the MidiBuffer's Array<uint8> structure is funny on Linux.
Anyone got any tips for me where to look or what to test next?