summaryrefslogtreecommitdiffstats
path: root/src/glu
diff options
context:
space:
mode:
authorLukas Rössler <pontomedon@gmail.com>2012-05-21 08:29:21 -0600
committerBrian Paul <brianp@vmware.com>2012-05-21 08:29:23 -0600
commit6178b653c766beeb8a6ad37134a6ee1a246a0c18 (patch)
tree869cf1fbd0cb050f81a3db1610c1dfd69e109734 /src/glu
parented9d1bef81c9a5601f81d65ebbf30335c485a48e (diff)
downloadexternal_mesa3d-6178b653c766beeb8a6ad37134a6ee1a246a0c18.zip
external_mesa3d-6178b653c766beeb8a6ad37134a6ee1a246a0c18.tar.gz
external_mesa3d-6178b653c766beeb8a6ad37134a6ee1a246a0c18.tar.bz2
glu: fix two Clang warnings
This patch removes two Clang warnings in GLU: The first one seems to be an actual bug in mapdesc.cc: Clang complains that sizeof(dest) will return the size of REAL*[MAXCOORDS], instead of the intended REAL[MAXCOORDS][MAXCOORDS]. The second one is just cosmetic because Clang doesn't like extra parentheses. NOTE: This is a candidate for the 8.0 branch Reviewed-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src/glu')
-rw-r--r--src/glu/sgi/libnurbs/internals/mapdesc.cc2
-rw-r--r--src/glu/sgi/libnurbs/internals/nurbstess.cc2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/glu/sgi/libnurbs/internals/mapdesc.cc b/src/glu/sgi/libnurbs/internals/mapdesc.cc
index d59f8fd..0a96c5f 100644
--- a/src/glu/sgi/libnurbs/internals/mapdesc.cc
+++ b/src/glu/sgi/libnurbs/internals/mapdesc.cc
@@ -90,7 +90,7 @@ Mapdesc::setBboxsize( INREAL *mat )
void
Mapdesc::identify( REAL dest[MAXCOORDS][MAXCOORDS] )
{
- memset( dest, 0, sizeof( dest ) );
+ memset( dest, 0, sizeof( REAL ) * MAXCOORDS * MAXCOORDS );
for( int i=0; i != hcoords; i++ )
dest[i][i] = 1.0;
}
diff --git a/src/glu/sgi/libnurbs/internals/nurbstess.cc b/src/glu/sgi/libnurbs/internals/nurbstess.cc
index 68dfd95..e477a8c 100644
--- a/src/glu/sgi/libnurbs/internals/nurbstess.cc
+++ b/src/glu/sgi/libnurbs/internals/nurbstess.cc
@@ -505,7 +505,7 @@ NurbsTessellator::do_pwlcurve( O_pwlcurve *o_pwlcurve )
o_pwlcurve->owner = currentCurve;
}
- if( (inCurve == 2) )
+ if( inCurve == 2 )
endcurve();
}