changeset 106 | a540a842ddef |
parent 77 | 49e0babccb23 |
--- a/endian.c +++ b/endian.c @@ -11,12 +11,12 @@ unsigned short word = 0x1234; unsigned char *p = (unsigned char *)&word; - return ((p[0] == 0x34) ? 0 : 1); + return (p[0] == 0x34); } int main (int argc, char **argv) { - printf ("%s Endian System\n", (endian ())? "Big" : "Little"); + printf ("%s Endian System\n", (endian ())? "Little" : "Big"); return EXIT_SUCCESS; }