From e5f665c7187b6934a71169cab5075f899150f17a Mon Sep 17 00:00:00 2001 From: marxin Date: Thu, 21 Feb 2019 20:57:39 +0100 Subject: Fix -Wsign-compare warnings. I decided to modify code in a defensive way. Ideally functions like size() or length() should return an unsigned type. --- modules/pvr/texture_loader_pvr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'modules/pvr') diff --git a/modules/pvr/texture_loader_pvr.cpp b/modules/pvr/texture_loader_pvr.cpp index 01e011e64c..82f323e8cf 100644 --- a/modules/pvr/texture_loader_pvr.cpp +++ b/modules/pvr/texture_loader_pvr.cpp @@ -216,7 +216,7 @@ static void _compress_pvrtc4(Image *p_img) { int ofs, size, w, h; img->get_mipmap_offset_size_and_dimensions(i, ofs, size, w, h); Javelin::RgbaBitmap bm(w, h); - for (unsigned j = 0; j < size / 4; j++) { + for (int j = 0; j < size / 4; j++) { Javelin::ColorRgba *dp = bm.GetData(); /* red and Green colors are swapped. */ new (dp) Javelin::ColorRgba(r[ofs + 4 * j + 2], r[ofs + 4 * j + 1], r[ofs + 4 * j], r[ofs + 4 * j + 3]); -- cgit v1.2.3