kwin/libkwineffects
Martin Gräßlin d49fba5d30 [libkwinxrenderutils] Clean up static blend picture before going down
Summary:
The method xRenderBlendPicture created a static XRenderPicture on
first usage. To cleanup a XRenderPicture an xcb_connection_t* is needed.
As it's static the cleanup happens on exit handler and at that time Qt
already destroyed the xcb_connection_t*. With a certain chance this will
crash.

To expose the problem a Q_ASSERT(qApp) is added in the destructor of
XRenderPicture. Using xrenderBlendPicture() will hit this assert on
application exit. This is demonstrated by the added auto test.

The actual fix to the problem is moving the static variable out of
the method and introduce a global cleanup method just like the init
method. This is now called from Workspace dtor, so before application
goes down.

CCBUG: 363251

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D1731
2016-06-13 15:29:07 +02:00
..
autotests Unit test for WindowQuadList::makeGrid and ::makeRegularGrid 2013-11-25 09:27:31 +01:00
anidata.cpp optimize string operations 2015-11-05 14:14:06 +00:00
anidata_p.h use a global static for animation ids 2016-03-23 12:03:31 +01:00
CMakeLists.txt [libkwinglutils] Cleanup Shader API: removal of ShaderType 2016-01-26 09:42:49 +01:00
kwinanimationeffect.cpp use a global static for animation ids 2016-03-23 12:03:31 +01:00
kwinanimationeffect.h allow to retarget animations 2016-02-16 13:59:22 +01:00
kwinconfig.h.cmake Bind building of glx support on whether epoxy has a glx header 2015-11-03 09:29:31 +01:00
kwineffects.cpp Be sure isCurrentTab returns true 2016-06-01 20:46:35 +03:00
kwineffects.h [kwineffects] Expose fullScreen property in EffectWindow 2016-02-01 08:43:46 +01:00
kwinglcolorcorrection.cpp [libkwinglutils] Cleanup Shader API: removal of ShaderType 2016-01-26 09:42:49 +01:00
kwinglcolorcorrection.h Replace NULL with nullptr in libkwineffects 2014-01-08 11:55:49 +01:00
kwinglcolorcorrection_p.h Remove most calls to checkGLError() 2014-11-25 21:57:57 +01:00
kwinglobals.h Destroy static Client helper window before application goes down 2016-05-17 14:17:07 +02:00
kwinglplatform.cpp optimize string operations 2015-11-05 14:14:06 +00:00
kwinglplatform.h optimize string operations 2015-11-05 14:14:06 +00:00
kwingltexture.cpp [kwinglutils] Don't setup old shader API for rendering a texture 2016-01-25 14:11:54 +01:00
kwingltexture.h Check GL version and/or extension for using texture format GL_R8 2015-02-18 09:09:50 +01:00
kwingltexture_p.h Check GL version and/or extension for using texture format GL_R8 2015-02-18 09:09:50 +01:00
kwinglutils.cpp depend glsl on TextureNPOT, not LimitedNPOT 2016-02-02 11:06:37 +01:00
kwinglutils.h [effects] Combine all shaders in resources 2016-02-01 08:42:30 +01:00
kwinglutils_funcs.cpp Don't query for GL_CONTEXT_FLAGS if not at least OpenGL 3.0 2015-11-19 11:20:33 +01:00
kwinglutils_funcs.h Revert "Handle conflicts between epoxy and manually resolved function pointers" 2015-11-17 14:58:59 +01:00
kwinxrenderutils.cpp [libkwinxrenderutils] Clean up static blend picture before going down 2016-06-13 15:29:07 +02:00
kwinxrenderutils.h [libkwinxrenderutils] Clean up static blend picture before going down 2016-06-13 15:29:07 +02:00
logging.cpp [libkwineffects] Introduce logging categories for libkwineffects 2015-07-31 12:16:15 +02:00
logging_p.h [libkwineffects] Introduce logging categories for libkwineffects 2015-07-31 12:16:15 +02:00
Mainpage.dox
Messages.sh