]> git.cworth.org Git - apitrace/commitdiff
Silence some warnings.
authorJosé Fonseca <jfonseca@vmware.com>
Wed, 23 Mar 2011 16:44:47 +0000 (16:44 +0000)
committerJosé Fonseca <jfonseca@vmware.com>
Wed, 23 Mar 2011 16:44:47 +0000 (16:44 +0000)
glsize.hpp
trace_parser.hpp

index 8d46ea512006e4d7f73ccff772b23f408b9e31d8..b42a3ec462a052f15d2f3ee1fcfc59a5e13a3ee9 100644 (file)
@@ -79,9 +79,9 @@ __gl_type_size(GLenum type)
 static inline size_t
 __glArrayPointer_size(GLint size, GLenum type, GLsizei stride, GLsizei maxIndex)
 {
-    GLsizei elementSize = size*__gl_type_size(type);
+    size_t elementSize = size*__gl_type_size(type);
     if (!stride) {
-        stride = elementSize;
+        stride = (GLsizei)elementSize;
     }
     return stride*maxIndex + elementSize;
 }
index dfaf42e4e29d31b9881b6e0283ff5b8e86ef0dc1..f008fb993401ec9cdbad4b7c8a97835fdeb88017 100644 (file)
@@ -319,7 +319,7 @@ public:
         size_t size = read_uint();
         Blob *blob = new Blob(size);
         if (size) {
-            gzread(file, blob->buf, size);
+            gzread(file, blob->buf, (unsigned)size);
         }
         return blob;
     }
@@ -360,7 +360,7 @@ public:
             return std::string();
         }
         char * buf = new char[len];
-        gzread(file, buf, len);
+        gzread(file, buf, (unsigned)len);
         std::string value(buf, len);
         delete [] buf;
 #if TRACE_VERBOSE