From: cloudwalk Date: Mon, 30 Nov 2020 18:11:09 +0000 (+0000) Subject: gl_textures: Fix warning X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=1887a6cacf37507f2e6878153450b25d53c650b5;p=xonotic%2Fdarkplaces.git gl_textures: Fix warning git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@13057 d7cf8633-e32d-0410-b094-e92efae38249 --- diff --git a/gl_textures.c b/gl_textures.c index fcb0bac7..b45c620b 100644 --- a/gl_textures.c +++ b/gl_textures.c @@ -2284,7 +2284,7 @@ void R_UpdateTexture(rtexture_t *rt, const unsigned char *data, int x, int y, in if (x < 0 || y < 0 || z < 0 || glt->tilewidth < x + width || glt->tileheight < y + height || glt->tiledepth < z + depth) Host_Error("R_UpdateTexture on buffered texture with out of bounds coordinates (%i %i %i to %i %i %i is not within 0 0 0 to %i %i %i)", x, y, z, x + width, y + height, z + depth, glt->tilewidth, glt->tileheight, glt->tiledepth); - for (j = 0; j < height; j++) + for (j = 0; j < (size_t)height; j++) memcpy(glt->bufferpixels + ((y + j) * glt->tilewidth + x) * bpp, data + j * width * bpp, width * bpp); switch(combine)