fix demo playback on 64-bit systems; bump demo minor version number to reflect changes in r1857

git-svn-id: https://svn.eduke32.com/eduke32@1864 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
helixhorned 2011-04-09 22:38:39 +00:00
parent 6127590367
commit 621da89b37

View file

@ -922,7 +922,7 @@ typedef struct dataspec_
} dataspec_t; } dataspec_t;
#define SV_MAJOR_VER 0 #define SV_MAJOR_VER 0
#define SV_MINOR_VER 2 #define SV_MINOR_VER 3
#define SV_DEFAULTCOMPRTHRES 8 #define SV_DEFAULTCOMPRTHRES 8
static uint8_t savegame_diffcompress; // 0:none, 1:Ken's LZW in cache1d.c static uint8_t savegame_diffcompress; // 0:none, 1:Ken's LZW in cache1d.c
static uint8_t savegame_comprthres; static uint8_t savegame_comprthres;
@ -1695,7 +1695,7 @@ int32_t sv_loadsnapshot(int32_t fil, int32_t *ret_hasdiffs, int32_t *ret_demotic
savegame_diffcompress = tmpbuf[7]; savegame_diffcompress = tmpbuf[7];
*ret_synccompress = (int32_t)tmpbuf[8]; *ret_synccompress = (int32_t)tmpbuf[8];
if (kread(fil, ret_demoticcnt, sizeof(ret_demoticcnt)) != sizeof(ret_demoticcnt)) goto corrupt; if (kread(fil, ret_demoticcnt, sizeof(*ret_demoticcnt)) != sizeof(*ret_demoticcnt)) goto corrupt;
if (kread(fil, &svsnapsiz, sizeof(svsnapsiz)) != sizeof(svsnapsiz)) goto corrupt; if (kread(fil, &svsnapsiz, sizeof(svsnapsiz)) != sizeof(svsnapsiz)) goto corrupt;