mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-27 04:00:42 +00:00
Fix a gcc 6.x warning
git-svn-id: https://svn.eduke32.com/eduke32@5831 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
c6617a98b2
commit
e3a7c98a25
1 changed files with 21 additions and 8 deletions
|
@ -4839,19 +4839,32 @@ DO_DEFSTATE:
|
||||||
// AddLog(g_szBuf);
|
// AddLog(g_szBuf);
|
||||||
}
|
}
|
||||||
g_numCases=0;
|
g_numCases=0;
|
||||||
|
|
||||||
if (tempscrptr)
|
if (tempscrptr)
|
||||||
{
|
{
|
||||||
intptr_t t,n;
|
for (i = 3; i < 3 + tempscrptr[1] * 2 - 2; i += 2) // sort them
|
||||||
for (i=3; i<3+tempscrptr[1]*2-2; i+=2) // sort them
|
|
||||||
{
|
{
|
||||||
t=tempscrptr[i]; n=i;
|
intptr_t t = tempscrptr[i];
|
||||||
for (j=i+2; j<3+tempscrptr[1]*2; j+=2)
|
intptr_t n = i;
|
||||||
if (tempscrptr[j]<t) {t=tempscrptr[j]; n=j;}
|
|
||||||
if (n!=i)
|
for (j = i + 2; j < 3 + tempscrptr[1] * 2; j += 2)
|
||||||
|
{
|
||||||
|
if (tempscrptr[j] < t)
|
||||||
{
|
{
|
||||||
t=tempscrptr[i ]; tempscrptr[i ]=tempscrptr[n ]; tempscrptr[n ]=t;
|
t = tempscrptr[j];
|
||||||
t=tempscrptr[i+1]; tempscrptr[i+1]=tempscrptr[n+1]; tempscrptr[n+1]=t;
|
n = j;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (n != i)
|
||||||
|
{
|
||||||
|
t = tempscrptr[i];
|
||||||
|
tempscrptr[i] = tempscrptr[n];
|
||||||
|
tempscrptr[n] = t;
|
||||||
|
t = tempscrptr[i + 1];
|
||||||
|
tempscrptr[i + 1] = tempscrptr[n + 1];
|
||||||
|
tempscrptr[n + 1] = t;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
// for (j=3;j<3+tempscrptr[1]*2;j+=2)initprintf("%5d %8x\n",tempscrptr[j],tempscrptr[j+1]);
|
// for (j=3;j<3+tempscrptr[1]*2;j+=2)initprintf("%5d %8x\n",tempscrptr[j],tempscrptr[j+1]);
|
||||||
tempscrptr[0]= (intptr_t)g_scriptPtr - (intptr_t)&apScript[0]; // save 'end' location
|
tempscrptr[0]= (intptr_t)g_scriptPtr - (intptr_t)&apScript[0]; // save 'end' location
|
||||||
|
|
Loading…
Reference in a new issue