[virglrenderer-devel] [PATCH v2 05/15] gallium/aux/tgsi_build.c: Fix -Wsign-compare warnings
Gert Wollny
gert.wollny at collabora.com
Tue Jun 5 20:19:53 UTC 2018
tgsi/tgsi_build.c: In function 'tgsi_build_full_immediate':
tgsi/tgsi_build.c:622:18: warning: comparison between signed and
unsigned integer expressions [-Wsign-compare]
for( i = 0; i < full_imm->Immediate.NrTokens - 1; i++ ) {
^
tgsi/tgsi_build.c: In function 'tgsi_build_full_property':
tgsi/tgsi_build.c:1393:18: warning: comparison between signed and
unsigned integer expressions [-Wsign-compare]
for( i = 0; i < full_prop->Property.NrTokens - 1; i++ ) {
^
Signed-off-by: Gert Wollny <gert.wollny at collabora.com>
---
src/gallium/auxiliary/tgsi/tgsi_build.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/gallium/auxiliary/tgsi/tgsi_build.c b/src/gallium/auxiliary/tgsi/tgsi_build.c
index a57f2e3..2132d2f 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_build.c
+++ b/src/gallium/auxiliary/tgsi/tgsi_build.c
@@ -584,7 +584,8 @@ tgsi_build_full_immediate(
struct tgsi_header *header,
unsigned maxsize )
{
- unsigned size = 0, i;
+ unsigned size = 0;
+ int i;
struct tgsi_immediate *immediate;
if( maxsize <= size )
@@ -1290,7 +1291,8 @@ tgsi_build_full_property(
struct tgsi_header *header,
unsigned maxsize )
{
- unsigned size = 0, i;
+ unsigned size = 0;
+ int i;
struct tgsi_property *property;
if( maxsize <= size )
--
2.16.4
More information about the virglrenderer-devel
mailing list