diff options
author | Olivier Bertrand <bertrandop@gmail.com> | 2015-06-03 11:31:18 +0200 |
---|---|---|
committer | Olivier Bertrand <bertrandop@gmail.com> | 2015-06-03 11:31:18 +0200 |
commit | 37a803c80520974c1c97661d7d578b056824ecdc (patch) | |
tree | 68f1ddd789f36e0c6b771c24c07630010af6a718 /storage/connect/xindex.h | |
parent | 65ed25446807efc0fe4482b69f6d76bf830c29f8 (diff) | |
download | mariadb-git-37a803c80520974c1c97661d7d578b056824ecdc.tar.gz |
Fix swapping key numeric values on Big Endian machines.
Swap the key length when WORDS_BIGENDIAN is defined
Make the IOFF structure depending on WORDS_BIGENDIAN
modified: storage/connect/connect.cc
modified: storage/connect/xindex.h
Diffstat (limited to 'storage/connect/xindex.h')
-rw-r--r-- | storage/connect/xindex.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/storage/connect/xindex.h b/storage/connect/xindex.h index a4e98075222..51b678992ea 100644 --- a/storage/connect/xindex.h +++ b/storage/connect/xindex.h @@ -65,7 +65,11 @@ typedef struct index_def : public BLOCK { typedef struct index_off { union { +#if defined(WORDS_BIGENDIAN) + struct {int High; int Low;}; +#else // !WORDS_BIGENDIAN struct {int Low; int High;}; +#endif //!WORDS_BIGENDIAN longlong Val; // File position }; // end of union } IOFF; |