as discussed with fuh, hide the endian dependency of the checksum calcs

(evil way of using md4, but oh well).
This commit is contained in:
Bill Currie 2004-05-16 23:17:51 +00:00
parent d25f2c87ea
commit 986dae9ec9
2 changed files with 2 additions and 2 deletions

View file

@ -834,7 +834,6 @@ Mod_LoadBrushModel (model_t *mod, void *buffer)
if (i == LUMP_ENTITIES)
continue;
csum = Com_BlockChecksum (mod_base + lump->fileofs, lump->filelen);
csum = LittleLong (csum);
mod->checksum ^= csum;
if (i != LUMP_VISIBILITY && i != LUMP_LEAFS && i != LUMP_NODES)

View file

@ -46,6 +46,7 @@ static __attribute__ ((unused)) const char rcsid[] =
#include "QF/checksum.h"
#include "QF/crc.h"
#include "QF/mdfour.h"
#include "QF/qendian.h"
static byte chktbl[1024 + 4] = {
0x78, 0xd2, 0x94, 0xe3, 0x41, 0xec, 0xd6, 0xd5,
@ -160,7 +161,7 @@ Com_BlockChecksum (const void *buffer, int length)
val = digest[0] ^ digest[1] ^ digest[2] ^ digest[3];
return val;
return LittleLong (val);
}
void