# HG changeset patch # User Mychaela Falconia # Date 1449950871 0 # Node ID 2a867e5768e9954733e1608050cfcd68c42ee14e # Parent 0b7abc72e49e31a19a53559659edc842e0b1e690 fc-dspapidump fix: be independent of host byte order diff -r 0b7abc72e49e -r 2a867e5768e9 rvinterf/etmsync/dspapidump.c --- a/rvinterf/etmsync/dspapidump.c Sat Dec 12 19:39:02 2015 +0000 +++ b/rvinterf/etmsync/dspapidump.c Sat Dec 12 20:07:51 2015 +0000 @@ -9,8 +9,8 @@ #include #include #include +#include #include -#include "localtypes.h" #include "exitcodes.h" #define APIF_ADDR 0xFFD00000 @@ -18,7 +18,7 @@ single_op_main() { - u16 buf[64], *linebase; + uint16_t buf[64], *linebase; unsigned off; int rc, i, j; @@ -30,7 +30,7 @@ printf("%04X:", off); linebase = buf + i * 8; for (j = 0; j < 8; j++) - printf(" %04X", linebase[j]); + printf(" %04X", le16toh(linebase[j])); putchar('\n'); off += 8; }