Use stack instead of broken usage of QByteBuffer

The internal buffer should not be used blindly when reading
Frame::HEADER_SIZE, as it is error prone and adds nothing over reading
on the stack (and it's only 7 bytes). There are places in this class
where buffer.clear() is called.
Move frame processing logic to separate function

This effectively removes 2 levels of indentation.
Fix alignment issues

Apparently, Qt has a nice function

  T qFromBigEndian(const uchar * src)

as well as the,

  T qFromBigEndian(T src)

The difference is the 2nd one requires properly aligned T, and the
first one reads it one byte at a time removing the alignment
constraints.
Make sure we can find the library in unit tests