aboutsummaryrefslogtreecommitdiffstats
path: root/epan/proto.h
diff options
context:
space:
mode:
authorGuy Harris <gharris@sonic.net>2020-08-02 00:34:06 -0700
committerGuy Harris <gharris@sonic.net>2020-08-02 08:30:09 +0000
commit2356415cfe8b2edb5cfb94da1281996b66c47568 (patch)
tree72d1fc21829481c5c2a7fed750cd9a9fbc38c894 /epan/proto.h
parent93260afcffb55e33fba8187fafe0474184735967 (diff)
libwireshark: define ENC_ANTI_HOST_ENDIAN in epan/proto.h.
We have two places where we want to dissect some fields as being in the opposite byte ordere from the host on which we're running; move the definition of ENC_ANTI_HOST_ENDIAN from packet-socketcan.c to proto.h, and use it in packet-enc.c. Change-Id: I1d0f9b037fe3b8ca6ed774a11063ba518a3922bf Reviewed-on: https://code.wireshark.org/review/38023 Petri-Dish: Guy Harris <gharris@sonic.net> Tested-by: Petri Dish Buildbot Reviewed-by: Guy Harris <gharris@sonic.net>
Diffstat (limited to 'epan/proto.h')
-rw-r--r--epan/proto.h6
1 files changed, 4 insertions, 2 deletions
diff --git a/epan/proto.h b/epan/proto.h
index cff21accb6..8938c5bb43 100644
--- a/epan/proto.h
+++ b/epan/proto.h
@@ -340,9 +340,11 @@ void proto_report_dissector_bug(const char *format, ...)
#define ENC_LITTLE_ENDIAN 0x80000000
#if G_BYTE_ORDER == G_LITTLE_ENDIAN
- #define ENC_HOST_ENDIAN ENC_LITTLE_ENDIAN
+ #define ENC_HOST_ENDIAN ENC_LITTLE_ENDIAN
+ #define ENC_ANTI_HOST_ENDIAN ENC_BIG_ENDIAN
#else
- #define ENC_HOST_ENDIAN ENC_BIG_ENDIAN
+ #define ENC_HOST_ENDIAN ENC_BIG_ENDIAN
+ #define ENC_ANTI_HOST_ENDIAN ENC_LITTLE_ENDIAN
#endif
/*