fix shader binary compilation to work with lazy compilation
[platform/core/uifw/dali-core.git] / dali / internal / render / gl-resources / context.cpp
index 5138ca3..2208d54 100644 (file)
@@ -345,6 +345,9 @@ void Context::ResetGlState()
   // get maximum texture size
   mGlAbstraction.GetIntegerv(GL_MAX_TEXTURE_SIZE, &mMaxTextureSize);
 
+  // reset any potential previous errors
+  mGlAbstraction.GetError();
+
   GLint numProgramBinaryFormats;
   mGlAbstraction.GetIntegerv(GL_NUM_PROGRAM_BINARY_FORMATS_OES, &numProgramBinaryFormats);
   if( GL_NO_ERROR == mGlAbstraction.GetError() && 0 != numProgramBinaryFormats )