Endian bugs suck; CSQC now works on big endian systems.
git-svn-id: https://svn.code.sf.net/p/fteqw/code/trunk@2881 fc73d0e0-1445-4013-8a0c-d673dee63da5
This commit is contained in:
parent
ff6630d28c
commit
0aa29e47e7
1 changed files with 4 additions and 4 deletions
|
@ -3542,7 +3542,7 @@ qbyte *CSQC_PRLoadFile (char *path, void *buffer, int bufsize)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Com_BlockChecksum(file, com_filesize) == csqcchecksum) //and the user wasn't trying to be cunning.
|
if (LittleLong(Com_BlockChecksum(file, com_filesize)) == csqcchecksum) //and the user wasn't trying to be cunning.
|
||||||
return file;
|
return file;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3557,7 +3557,7 @@ qbyte *CSQC_PRLoadFile (char *path, void *buffer, int bufsize)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Com_BlockChecksum(file, com_filesize) != csqcchecksum)
|
if (LittleLong(Com_BlockChecksum(file, com_filesize)) != csqcchecksum)
|
||||||
return NULL; //not valid
|
return NULL; //not valid
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -3591,7 +3591,7 @@ int CSQC_PRFileSize (char *path)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Com_BlockChecksum(file, com_filesize) == csqcchecksum) //and the user wasn't trying to be cunning.
|
if (LittleLong(Com_BlockChecksum(file, com_filesize)) == csqcchecksum) //and the user wasn't trying to be cunning.
|
||||||
return com_filesize+1;
|
return com_filesize+1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -3606,7 +3606,7 @@ int CSQC_PRFileSize (char *path)
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (Com_BlockChecksum(file, com_filesize) != csqcchecksum)
|
if (LittleLong(Com_BlockChecksum(file, com_filesize)) != csqcchecksum)
|
||||||
return -1; //not valid
|
return -1; //not valid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue