Comparison between boolean and integer. 77/102777/3
authorFrancisco Santos <f1.santos@samsung.com>
Tue, 6 Dec 2016 10:29:01 +0000 (10:29 +0000)
committerFrancisco Santos <f1.santos@samsung.com>
Fri, 16 Dec 2016 16:46:07 +0000 (16:46 +0000)
Change-Id: I565aee867965ab67bd8d5c97e3ac620a893f4925

dali/internal/render/gl-resources/context.h

index 136f09b..28afbfd 100644 (file)
@@ -700,11 +700,12 @@ public:
    */
   void DepthMask(GLboolean flag)
   {
+    bool booleanFlag = flag != GL_FALSE;
     // only change state if needed
-    if( flag != mDepthMaskEnabled )
+    if( booleanFlag != mDepthMaskEnabled )
     {
-      mDepthMaskEnabled = flag;
-      LOG_GL("DepthMask %s\n", flag ? "True" : "False");
+      mDepthMaskEnabled = booleanFlag;
+      LOG_GL("DepthMask %s\n", booleanFlag ? "True" : "False");
       CHECK_GL( mGlAbstraction, mGlAbstraction.DepthMask( mDepthMaskEnabled ) );
     }
   }