From: Stanislav Vorobiov Date: Fri, 9 Aug 2013 13:45:53 +0000 (+0400) Subject: YaGL: Don't check 'target' in eglCreateImageKHR X-Git-Tag: Tizen_Studio_1.3_Release_p2.3.1~806^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=3ab435c5769f0e1f89cbdc0e8ad00b40f80f8be2;p=sdk%2Femulator%2Fqemu.git YaGL: Don't check 'target' in eglCreateImageKHR Target code will handle this --- diff --git a/hw/yagl_apis/egl/yagl_host_egl_calls.c b/hw/yagl_apis/egl/yagl_host_egl_calls.c index d9c87aad37..b86002acbd 100644 --- a/hw/yagl_apis/egl/yagl_host_egl_calls.c +++ b/hw/yagl_apis/egl/yagl_host_egl_calls.c @@ -1606,49 +1606,13 @@ bool yagl_host_eglCreateImageKHR(yagl_host_handle* retval, yagl_winsys_id buffer, target_ulong /* const EGLint* */ attrib_list_) { - bool res = true; - EGLint *attrib_list = NULL; struct yagl_egl_display *dpy = NULL; struct yagl_egl_image *image = NULL; - int i = 0; YAGL_LOG_FUNC_SET(eglCreateImageKHR); *retval = 0; - if (ctx) { - YAGL_SET_ERR(EGL_BAD_PARAMETER); - goto out; - } - - if (target != EGL_NATIVE_PIXMAP_KHR) { - YAGL_SET_ERR(EGL_BAD_PARAMETER); - goto out; - } - - if (attrib_list_) { - attrib_list = yagl_mem_get_attrib_list(attrib_list_); - - if (!attrib_list) { - res = false; - goto out; - } - } - - if (!yagl_egl_is_attrib_list_empty(attrib_list)) { - while (attrib_list[i] != EGL_NONE) { - switch (attrib_list[i]) { - case EGL_IMAGE_PRESERVED_KHR: - break; - default: - YAGL_SET_ERR(EGL_BAD_ATTRIBUTE); - goto out; - } - - i += 2; - } - } - if (!yagl_validate_display(dpy_, &dpy)) { goto out; } @@ -1666,9 +1630,7 @@ bool yagl_host_eglCreateImageKHR(yagl_host_handle* retval, *retval = image->res.handle; out: - g_free(attrib_list); - - return res; + return true; } bool yagl_host_eglDestroyImageKHR(EGLBoolean* retval,