Just cleaning a couple of things up.

Also added a frame->size containing complete frame size.
This is an unsigned int.  This means I'm abandoning
the idea of greater than 32 bit frame sizes.
I'm going to modify the code and drop the 64 bit
payload_len.  Will ensure frames up to 32 bit
in size will work.  This means payload will have to
be = 2^32 - (max frame header size).  I don't
foresee a whole lot of approximate 4GB frames
so this shouldn't be a problem.  If you need > 4GB
frames, use another library.  ;)