ports/graphics/mesa-demos/files/patch-src_egl_opengl_eglkms.c
Baptiste Daroussin 31ae1852c8 Enable the EGL and GLESv2 demos
PR:		214708
Submitted by:	matthew@reztek.cz
2017-01-22 21:44:36 +00:00

16 lines
577 B
C

# Fix an uninitialized variable in a particular execution path
#
# While it would be better design to initialize the error value
# at the start, it is set in every other error path so the least
# intrusive correction is to set it in the one missed path.
#
--- src/egl/opengl/eglkms.c.orig 2012-08-28 14:31:17 UTC
+++ src/egl/opengl/eglkms.c
@@ -212,6 +212,7 @@ int main(int argc, char *argv[])
if (!eglChooseConfig(dpy, attribs, &config, 1, &n) || n != 1) {
fprintf(stderr, "failed to choose argb config\n");
+ ret = -1;
goto egl_terminate;
}