On 09/25/2013 12:01 PM, Jeff Cody wrote: > It is from UML, right? Is there an official spec that is still around > (most of the links I have found suffer from link rot)? The closest I > could find to a spec were old UML patches for x86_64 that cleaned up > some data types, so that the following was defined: > > struct cow_header_v2 { > > __u32 magic; > __u32 version; > char backing_file[PATH_LEN_V2]; > time_t mtime; > __u64 size; > int sectorsize; > }; > > That remains ambiguous, although given the era I suppose it could be > argued that 32-bit architecture and alignment is assumed. But if this > is the original spec, then it seems like a non-portable one.
Indeed. Not just the potential padding there, but of course the size of time_t varies between hosts. And since we use an int32_t not time_t, we're not even necessarily compatible with UML. r~