Re: [fpc-pascal] TOpenGLControl segfaults on re-parenting

2019-04-07 Thread denisgolovan
Bug report and patch with fix filed to https://bugs.freepascal.org/view.php?id=35335 Please review. -- Regards, Denis Golovan ___ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal

Re: [fpc-pascal] TOpenGLControl segfaults on re-parenting

2019-04-06 Thread denisgolovan
Some more information on the matter. While investigating the issue I noticed that gtk_gl_area_destroy is called twice for single OpenGL widget when changing Parent property. That does not look nice as it accesses freed memory second time it calls gdk_gl_context_unref (context : PGdkGLContextPriv

[fpc-pascal] TOpenGLControl segfaults on re-parenting

2019-04-06 Thread denisgolovan
Hi all I experience various random segfaults when trying to change Parent for TOpenGLControl. Unfortunately it happens rather randomly. Sometimes it happens deep in GTK code, sometimes when GL context destroys. I am under Linux + GTK-2.24.32 + Mesa 19.0.1 (amdgpu driver). Does anybody experien