Fixed compilation warnings reported by GCC/Clang
gl/data/gl_setup.cpp:430:11: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] gl/data/gl_setup.cpp:527:19: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] gl/data/gl_setup.cpp:542:19: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] nodebuild.cpp:1056:63: warning: format specifies type 'ptrdiff_t' (aka 'long') but the argument has type 'int' [-Wformat] p_glnodes.cpp:379:50: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] p_saveg.cpp:381:18: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] p_scroll.cpp:532:11: warning: comparison of integers of different signs: 'int' and 'unsigned int' [-Wsign-compare] p_setup.cpp:2304:43: warning: format specifies type 'int' but the argument has type 'unsigned long' [-Wformat] p_setup.cpp:2302:12: warning: comparison of integers of different signs: 'int' and 'unsigned long' [-Wsign-compare] scripting/codegeneration/codegen.cpp:8488:20: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare] scripting/codegeneration/codegen.cpp:8606:15: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
This commit is contained in:
parent
f83444f3cc
commit
0b62645a35
7 changed files with 15 additions and 18 deletions
|
|
@ -399,20 +399,15 @@ static void AddToVertex(const sector_t * sec, TArray<int> & list)
|
|||
|
||||
static void InitVertexData()
|
||||
{
|
||||
TArray<int> * vt_sectorlists;
|
||||
|
||||
int i,j,k;
|
||||
|
||||
vt_sectorlists = new TArray<int>[level.vertexes.Size()];
|
||||
|
||||
auto vt_sectorlists = new TArray<int>[level.vertexes.Size()];
|
||||
|
||||
for(auto &line : level.lines)
|
||||
{
|
||||
for(j=0;j<2;j++)
|
||||
for(int j = 0; j < 2; ++j)
|
||||
{
|
||||
vertex_t * v = j==0? line.v1 : line.v2;
|
||||
|
||||
for(k=0;k<2;k++)
|
||||
for(int k = 0; k < 2; ++k)
|
||||
{
|
||||
sector_t * sec = k==0? line.frontsector : line.backsector;
|
||||
|
||||
|
|
@ -427,7 +422,7 @@ static void InitVertexData()
|
|||
}
|
||||
}
|
||||
|
||||
for(i=0;i<level.vertexes.Size();i++)
|
||||
for(unsigned i = 0; i < level.vertexes.Size(); ++i)
|
||||
{
|
||||
auto vert = level.vertexes[i];
|
||||
int cnt = vt_sectorlists[i].Size();
|
||||
|
|
@ -524,7 +519,7 @@ static void PrepareSegs()
|
|||
level.sides[0].segs = new seg_t*[realsegs];
|
||||
level.sides[0].numsegs = 0;
|
||||
|
||||
for(int i = 1; i < numsides; i++)
|
||||
for(unsigned i = 1; i < numsides; i++)
|
||||
{
|
||||
level.sides[i].segs = level.sides[i-1].segs + segcount[i-1];
|
||||
level.sides[i].numsegs = 0;
|
||||
|
|
@ -539,7 +534,7 @@ static void PrepareSegs()
|
|||
}
|
||||
|
||||
// sort the segs
|
||||
for(int i = 0; i < numsides; i++)
|
||||
for(unsigned i = 0; i < numsides; i++)
|
||||
{
|
||||
if (level.sides[i].numsegs > 1) qsort(level.sides[i].segs, level.sides[i].numsegs, sizeof(seg_t*), segcmp);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue