Skip to content

egl: refactors fallbacks

Eric Engestrom requested to merge eric/mesa:misc/egl-refactor into master

Most of these fallbacks were abusing returning EGL_FALSE and casting it into whatever the function returns, be that a boolean, a context, a surface, a sync, etc.

They were also all failing to set an error, even though they were returning a "failed" status. I chose EGL_NOT_INITIALIZED as it is the closest to a reasonable error in most cases, and anyway it should only ever be seen while developing a driver or implementing an extension, and never in properly-behaved clients using shipping versions of Mesa.

Not 100% sure about the last commit ("egl: move fallback calls to eglapi.c"), it doesn't really add much, but it does get rid of the file 🤷

Merge request reports