From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Wed, 6 Sep 1995 18:32:20 -0400 From: Steve Hemminger sch@postman.ncube.com Subject: botch on long long byte order Topicbox-Message-UUID: 214a86b0-eac8-11e9-9e20-41e7f4b1d025 Message-ID: <19950906223220.6ZbPZL48mFzsqdsEbhoVL2D4UN5eSNqW8KUdv52Kw-E@z> Order of elements in Length union is incorrect: :Program to demonstrate: ------------- #include #include Length l; void main(int argc, char *argv[]) { USED(argc, argv); l.length = 1; l.hlength=0; print("should be 1 is %lld\n", l.vlength); l.hlength = 1; l.length = 0; print("should be 0x100000000 is %ullx\n", l.vlength); l.vlength = 1; print("should be 1 (0/1) is %lld (%ld/%ld)\n", l.vlength, l.hlength, l.length); } : I get ------------- should be 1 is 4294967296 should be 0x100000000 is 1 should be 1 (0/1) is 1 (1/0) ------------- WARNING: putting them in the correct order (/386/include/u.h) will mean rebuilding the world though since the file system is byte order independant, the disk does not need to be reloaded.