[Mesa-dev] [PATCH] egl: fix build after introduction of new member in _egl_thread_info
Rob Herring
robh at kernel.org
Thu Jun 2 21:54:54 UTC 2016
On Thu, Jun 2, 2016 at 4:45 PM, Tobias Klausmann
<tobias.johannes.klausmann at mni.thm.de> wrote:
> Starting with commit e8b38ca202fbe8c281aeb81a4b64256983f185e0 the dummy_thread
> misses the proper intialization for the new member, leading to the error stated
> at the bottom. This patch initializes the new member.
Just hit this too (trying to test the last Android build failures, sigh).
> Signed-off-by: Tobias Klausmann <tobias.johannes.klausmann at mni.thm.de>
Your SoB should be last after the error message.
>
> CC main/eglcurrent.lo
> In file included from main/egltypedefs.h:34:0,
> from main/egllog.h:34,
> from main/eglcurrent.c:34:
> ../../include/EGL/egl.h:109:43: warning: initialization makes pointer from
> integer without a cast [-Wint-conversion]
> #define EGL_SUCCESS 0x3000
> ^
> main/eglcurrent.c:41:6: note: in expansion of macro ‘EGL_SUCCESS’
> { EGL_SUCCESS, { NULL }, 0 }
> ^
> main/eglcurrent.c:44:38: note: in expansion of macro ‘
> _EGL_THREAD_INFO_INITIALIZER’
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> ^
> ../../include/EGL/egl.h:109:43: note: (near initialization for ‘
> dummy_thread.Next’)
> #define EGL_SUCCESS 0x3000
> ^
> main/eglcurrent.c:41:6: note: in expansion of macro ‘EGL_SUCCESS’
> { EGL_SUCCESS, { NULL }, 0 }
> ^
> main/eglcurrent.c:44:38: note: in expansion of macro ‘
> _EGL_THREAD_INFO_INITIALIZER’
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> ^
> main/eglcurrent.c:44:1: warning: braces around scalar initializer
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> ^
> main/eglcurrent.c:44:1: note: (near initialization for ‘dummy_thread.LastError’)
> main/eglcurrent.c:44:38: warning: initialization makes integer from pointer
> without a cast [-Wint-conversion]
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> ^
> main/eglcurrent.c:44:38: note: (near initialization for ‘
> dummy_thread.LastError’)
> main/eglcurrent.c:41:4: warning: missing braces around initializer
> [-Wmissing-braces]
> { EGL_SUCCESS, { NULL }, 0 }
> ^
> main/eglcurrent.c:44:38: note: in expansion of macro ‘
> _EGL_THREAD_INFO_INITIALIZER’
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> ^
> main/eglcurrent.c:41:4: note: (near initialization for ‘dummy_thread’)
> { EGL_SUCCESS, { NULL }, 0 }
> ^
> main/eglcurrent.c:44:38: note: in expansion of macro ‘
> _EGL_THREAD_INFO_INITIALIZER’
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
No point in displaying the repeated error here. Can you trim this some.
Otherwise, looks right to me.
Reviewed-by: Rob Herring <robh at kernel.org>
> ---
> src/egl/main/eglcurrent.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/src/egl/main/eglcurrent.c b/src/egl/main/eglcurrent.c
> index 835631d..2af53e4 100644
> --- a/src/egl/main/eglcurrent.c
> +++ b/src/egl/main/eglcurrent.c
> @@ -38,7 +38,7 @@
>
> /* This should be kept in sync with _eglInitThreadInfo() */
> #define _EGL_THREAD_INFO_INITIALIZER \
> - { EGL_SUCCESS, { NULL }, 0 }
> + { NULL, EGL_SUCCESS, { NULL }, 0 }
>
> /* a fallback thread info to guarantee that every thread always has one */
> static _EGLThreadInfo dummy_thread = _EGL_THREAD_INFO_INITIALIZER;
> --
> 2.8.3
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
More information about the mesa-dev
mailing list