Replace GL_NONE with GL_NO_ERROR when used as error.

GL_NONE is primarily a renderbuffer format, and GL_NO_ERROR more
clearly conveys the meaning when used as a validation return code.
Also, GL_NONE is not defined in OpenGL ES 1.1 (but GL_NONE_OES is,
as a renderbuffer format).

Change-Id: Ie1c00009c30c8d2717de15c7e27db295ecd9de1e
Reviewed-on: https://swiftshader-review.googlesource.com/17489
Tested-by: Nicolas Capens <nicolascapens@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
diff --git a/src/OpenGL/libGLESv2/libGLESv3.cpp b/src/OpenGL/libGLESv2/libGLESv3.cpp
index 5a11b0b..5006161 100644
--- a/src/OpenGL/libGLESv2/libGLESv3.cpp
+++ b/src/OpenGL/libGLESv2/libGLESv3.cpp
@@ -369,7 +369,7 @@
 	if(context)
 	{
 		GLenum validationError = ValidateTextureFormatType(format, type, internalformat, target, context->getClientVersion());
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
@@ -382,7 +382,7 @@
 		}
 
 		validationError = context->getPixels(&data, type, context->getRequiredBufferSize(width, height, depth, format, type));
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
@@ -419,19 +419,19 @@
 	}
 
 	es2::Context *context = es2::getContext();
-	
+
 	if(context)
 	{
 		es2::Texture3D *texture = (target == GL_TEXTURE_3D) ? context->getTexture3D() : context->getTexture2DArray();
 
 		GLenum validationError = ValidateSubImageParams(false, false, target, level, xoffset, yoffset, zoffset, width, height, depth, format, type, texture, context->getClientVersion());
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
 
 		validationError = context->getPixels(&data, type, context->getRequiredBufferSize(width, height, depth, format, type));
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
@@ -487,7 +487,7 @@
 		es2::Texture3D *texture = (target == GL_TEXTURE_3D) ? context->getTexture3D() : context->getTexture2DArray();
 
 		GLenum validationError = ValidateSubImageParams(false, true, target, level, xoffset, yoffset, zoffset, width, height, 1, GL_NONE, GL_NONE, texture, context->getClientVersion());
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
@@ -551,7 +551,7 @@
 		}
 
 		GLenum validationError = context->getPixels(&data, GL_UNSIGNED_BYTE, imageSize);
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}
@@ -638,7 +638,7 @@
 		}
 
 		GLenum validationError = context->getPixels(&data, GL_UNSIGNED_BYTE, imageSize);
-		if(validationError != GL_NONE)
+		if(validationError != GL_NO_ERROR)
 		{
 			return error(validationError);
 		}