The endianness of binary taxonomy files is now correctly checked

This commit is contained in:
Celine Mercier
2016-10-10 17:04:29 +02:00
parent 0faaac49cf
commit 0dfd67ec89
2 changed files with 50 additions and 27 deletions

View File

@ -17,6 +17,10 @@
#include "obidms.h"
#define SWAPINT32(x) ((((x) << 24) & 0xFF000000) | (((x) << 8) & 0xFF0000) | \
(((x) >> 8) & 0xFF00) | (((x) >> 24) & 0xFF))
typedef struct {
int32_t taxid;
int32_t rank;