On 04.05.2017 17:16, Bartosz Tomczyk wrote:
It fixes occasional crashes when app exits
and glthread is still processing commands.
---
src/mesa/main/context.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/src/mesa/main/context.c b/src/mesa/main/context.c
index 3570f94f5a..c3c4095329 100644
--- a/src/mesa/main/context.c
+++ b/src/mesa/main/context.c
@@ -354,6 +354,9 @@ mtx_t OneTimeLock = _MTX_INITIALIZER_NP;
static void
one_time_fini(void)
{
+ GET_CURRENT_CONTEXT(ctx);
+ if (ctx)
+ _mesa_glthread_destroy(ctx);
NAK, this makes no sense. one_time_fini is called once for the whole
process, but there might be many GL contexts per process, and each one
would have its own GL thread.
What are the crashes you're seeing? Let's fix the underlying problem
instead.
Cheers,
Nicolai
_mesa_destroy_shader_compiler();
_mesa_locale_fini();
}
--
Lerne, wie die Welt wirklich ist,
Aber vergiss niemals, wie sie sein sollte.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev