Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit dee20e5a authored by Chia-I Wu's avatar Chia-I Wu Committed by Android (Google) Code Review
Browse files

Merge "libEGL: silence warnings for client extension querying"

parents 46cf2b00 e57d1357
Loading
Loading
Loading
Loading
+10 −0
Original line number Diff line number Diff line
@@ -1133,6 +1133,16 @@ const char* eglQueryString(EGLDisplay dpy, EGLint name)
{
    clearError();

    // Generate an error quietly when client extensions (as defined by
    // EGL_EXT_client_extensions) are queried.  We do not want to rely on
    // validate_display to generate the error as validate_display would log
    // the error, which can be misleading.
    //
    // If we want to support EGL_EXT_client_extensions later, we can return
    // the client extension string here instead.
    if (dpy == EGL_NO_DISPLAY && name == EGL_EXTENSIONS)
        return setErrorQuiet(EGL_BAD_DISPLAY, nullptr);

    const egl_display_ptr dp = validate_display(dpy);
    if (!dp) return (const char *) NULL;