shared: Serialize total message size in messages

Have buxton_serialize_message include its total message size in the
data stream as well as return the message size as the functions return
value. This eliminates the need to use malloc_usable_size.
shared: Add function to get the size of a serialized message
shared: Add test for minimum stream message size

In case we get data from the client that doesn't make sense, don't
pass that on to anybody else.

Signed-off-by: William Douglas <william.douglas@intel.com>
shared: Also have a maximum size for messages

Signed-off-by: William Douglas <william.douglas@intel.com>
core: Add controls ability to handle partial messages

It is somewhat complex but the general idea is as follows. If this is
the first time processing something for this client, allocate a
minimally sized buffer and read in that minimum message size in order
to figure out the real length of the message (keep trying until there
is an error, nothing more to read or the buffer is filled). Once the
real length is known keep reading until that amount has been read and
process the message. If there isn't anything more to read and the full
message hasn't been loaded, just keep the current buffer and offsets
as they are and continue from there the next time the client writes.
If there was an error in the read or any other issue with bad looking
data, bail out and cleanup the buffer so the next time the client
sends data handling the message over from scratch.

This code currently is untested and very likely segfaults or behaves
incorrectly, please review.

Signed-off-by: William Douglas <william.douglas@intel.com>