Module: Mesa
Branch: master
Commit: cce04a463089ef3ce39df3e2ae25066c2e1ddfdf
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=cce04a463089ef3ce39df3e2ae25066c2e1ddfdf

Author: Rob Clark <robcl...@freedesktop.org>
Date:   Fri Nov 18 08:39:30 2016 -0500

egl: initialize SyncCondition after attr parsing

Reduce the noise in the next patch.  For EGL_SYNC_NATIVE_FENCE_ANDROID
the sync condition is conditional on EGL_SYNC_NATIVE_FENCE_FD_ANDROID
attribute.

Signed-off-by: Rob Clark <robcl...@freedesktop.org>
Tested-by: Rafael Antognolli <rafael.antogno...@intel.com>
Reviewed-by: Chad Versace <chadvers...@chromium.org>
Tested-by: Chad Versace <chadvers...@chromium.org>

---

 src/egl/main/eglsync.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/src/egl/main/eglsync.c b/src/egl/main/eglsync.c
index dea324b..005cb31 100644
--- a/src/egl/main/eglsync.c
+++ b/src/egl/main/eglsync.c
@@ -84,6 +84,8 @@ _eglInitSync(_EGLSync *sync, _EGLDisplay *dpy, EGLenum type,
    sync->Type = type;
    sync->SyncStatus = EGL_UNSIGNALED_KHR;
 
+   err = _eglParseSyncAttribList(sync, attrib_list);
+
    switch (type) {
    case EGL_SYNC_CL_EVENT_KHR:
       sync->SyncCondition = EGL_SYNC_CL_EVENT_COMPLETE_KHR;
@@ -92,7 +94,6 @@ _eglInitSync(_EGLSync *sync, _EGLDisplay *dpy, EGLenum type,
       sync->SyncCondition = EGL_SYNC_PRIOR_COMMANDS_COMPLETE_KHR;
    }
 
-   err = _eglParseSyncAttribList(sync, attrib_list);
    if (err != EGL_SUCCESS)
       return _eglError(err, "eglCreateSyncKHR");
 

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to