aboutsummaryrefslogtreecommitdiffstats
path: root/cmd/zdb/zdb.c
diff options
context:
space:
mode:
Diffstat (limited to 'cmd/zdb/zdb.c')
-rw-r--r--cmd/zdb/zdb.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/cmd/zdb/zdb.c b/cmd/zdb/zdb.c
index 18378c4e6..f050f36e2 100644
--- a/cmd/zdb/zdb.c
+++ b/cmd/zdb/zdb.c
@@ -3212,6 +3212,10 @@ zdb_dump_block(char *label, void *buf, uint64_t size, int flags)
(void) printf("\n%s\n%6s %s 0123456789abcdef\n", label, "", hdr);
+#ifdef _LITTLE_ENDIAN
+ /* correct the endianess */
+ do_bswap = !do_bswap;
+#endif
for (i = 0; i < nwords; i += 2) {
(void) printf("%06llx: %016llx %016llx ",
(u_longlong_t)(i * sizeof (uint64_t)),