aboutsummaryrefslogtreecommitdiff
path: root/graphics/mesa-demos/files/patch-src_egl_opengl_eglkms.c
blob: 5f9f35dd4c8f73edcbe9768bfa4c61aaba19f0d9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
# 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;
    }