diff --git a/src/nodebuild.cpp b/src/nodebuild.cpp index 90aaff492..83393f7c3 100644 --- a/src/nodebuild.cpp +++ b/src/nodebuild.cpp @@ -789,7 +789,7 @@ void FNodeBuilder::SplitSegs (DWORD set, node_t &node, DWORD splitseg, DWORD &ou newvert.y += fixed_t(frac * double(Vertices[seg->v2].y - newvert.y)); vertnum = VertexMap->SelectVertexClose (newvert); - if (vertnum == seg->v1 || vertnum == seg->v2) + if (vertnum == (unsigned int)seg->v1 || vertnum == (unsigned int)seg->v2) { Printf("SelectVertexClose selected endpoint of seg %u\n", set); } diff --git a/src/textures/ddstexture.cpp b/src/textures/ddstexture.cpp index ab5b4505d..da9ec5955 100644 --- a/src/textures/ddstexture.cpp +++ b/src/textures/ddstexture.cpp @@ -769,7 +769,7 @@ void FDDSTexture::DecompressDXT5 (FWadLump &lump, bool premultiplied, BYTE *tcbu BYTE *block; PalEntry color[4]; BYTE palcol[4]; - DWORD yalphaslice; + DWORD yalphaslice = 0; int ox, oy, x, y, i; for (oy = 0; oy < Height; oy += 4) diff --git a/src/v_text.cpp b/src/v_text.cpp index 715e06093..55dbcc774 100644 --- a/src/v_text.cpp +++ b/src/v_text.cpp @@ -317,7 +317,8 @@ FBrokenLines *V_BreakLines (FFont *font, int maxwidth, const BYTE *string) FBrokenLines lines[128]; // Support up to 128 lines (should be plenty) const BYTE *space = NULL, *start = string; - int i, c, w, nw; + size_t i, ii; + int c, w, nw; FString lastcolor, linecolor; bool lastWasSpace = false; int kerning = font->GetDefaultKerning (); @@ -418,11 +419,11 @@ FBrokenLines *V_BreakLines (FFont *font, int maxwidth, const BYTE *string) // Make a copy of the broken lines and return them FBrokenLines *broken = new FBrokenLines[i+1]; - for (c = 0; c < i; ++c) + for (ii = 0; ii < i; ++ii) { - broken[c] = lines[c]; + broken[ii] = lines[ii]; } - broken[c].Width = -1; + broken[ii].Width = -1; return broken; }