[parted-devel] Regarding little and big endian support

James Courtier-Dutton James at superbug.co.uk
Sat Jan 5 11:33:05 UTC 2008


xerces8 wrote:
> "Avinash Malik" <avimalik at gmail.com> wrote:
>
>   
>> #ifdef __LITTLE_ENDIAN
>> sblock.fs_version = PED_CPU_TO_LE32(fs_verison)
>> #endif
>> #ifdef __BIG_ENDIAN
>> sblock.fs_version = PED_CPU_TO_BE32(fs_version)
>> #endif
>>     
>
> This is the same as simply : sblock.fs_version = fs_version;
>   
No it is not.

> Find out how the on disk structure must be. Then adapt your code.
>
> Regards,
> David
>   




More information about the parted-devel mailing list