GNOME Bugzilla – Bug 660184
Running an X client causes a segfault when using software rendering
Last modified: 2011-10-16 09:50:20 UTC
Overview: Cogl segfaults when running an X client while software rendering is used (typically when GLX TFP could not be initialized). It happened when I was using 30-bit color depth. Steps to Reproduce: 1. Get hardware compatible with 30-bit color depth 2. startx -- -depth 30 3. Run any X client Actual Results: A segmentation fault occurs with the following trace:
+ Trace 228587
Created attachment 197525 [details] [review] cogl-winsys-glx: prevent a NULL pointer to be dereferenced This is a workaround to prevent the segfault. The actual fix would be to track where winsys might be dereferenced while its pointer is NULL.
Created attachment 197963 [details] [review] x11-tfp: don't call winsys x11_damage_notify without winsys thanks for your patch. I've made a slightly different patch that instead does the validation up in cogl-texture-pixmap-x11.c so that the winsys code can always assume a valid tex_pixmap->winsys code - It's only a minor difference but this way we don't lead to duplicate validation code in each winsys. If you would be able to verify that this patch works for you that would be greatly appreciated.
Thanks for making an actual patch. I applied it and couldn't reproduce the segfault as described in this bug report.
thanks for testing, I've landed the patch in master now as 1f61868fed78457c0.
Robert, can we have this change cherry-picked for cogl-1.8 branch?