C structs have packing, alignment, and endianness gotchas that can be portably addressed with byte-level de/ser.
Example: https://gist.github.com/cd089675a6088b0b8482c005a0e3897a