Use GLenum instead of GLint to store internal format variables.

TRAC #23785

Signed-off-by: Jamie Madill
Signed-off-by: Shannon Woods
diff --git a/src/libGLESv2/libGLESv2.cpp b/src/libGLESv2/libGLESv2.cpp
index bf8dc17..e85fe64 100644
--- a/src/libGLESv2/libGLESv2.cpp
+++ b/src/libGLESv2/libGLESv2.cpp
@@ -2211,7 +2211,7 @@
                 return gl::error(GL_INVALID_OPERATION);
             }
 
-            GLint internalFormat = texture->getBaseLevelInternalFormat();
+            GLenum internalFormat = texture->getBaseLevelInternalFormat();
 
             // Internally, all texture formats are sized so checking if the format
             // is color renderable and filterable will not fail.
@@ -4604,8 +4604,7 @@
 
         if (context)
         {
-            GLint currentInternalFormat;
-            GLenum currentFormat, currentType;
+            GLenum currentInternalFormat, currentFormat, currentType;
 
             // Failure in getCurrentReadFormatType indicates that no color attachment is currently bound,
             // and attempting to read back if that's the case is an error. The error will be registered
@@ -4648,8 +4647,7 @@
 
         if (context)
         {
-            GLint currentInternalFormat;
-            GLenum currentFormat, currentType;
+            GLenum currentInternalFormat, currentFormat, currentType;
 
             // Failure in getCurrentReadFormatType indicates that no color attachment is currently bound,
             // and attempting to read back if that's the case is an error. The error will be registered