Fixed kryo serialization errors (returned the output buffer instead of the entire byte array DOH!)