Skip to content

libweston/backend-headless: Remove cleanup_after_cairo()

In some circumstances (like load) we seem to be racing with the threads fontconfig creates and the resource release happening inside cleanup_after_cairo(). As that release is not a global one, being suitable only for the current running thread, we would still find a cached entry holding a font map reference while we are on the compositor exit path. This happens in cleanup_after_cairo() when calling cairo_debug_reset_static_data().

This was introduced with commit 823580e0, 'backend-headless: fully release pango and fontconfig', as a way to have a clean memory leak report not pointing to fontconfig/cairo but due to the fact we can't influence how libraries manage their threads, the solution (for now at least) would be to just remove it entirely.

Running it at the end in the test itself, or before calling exit(2), while it doe narrow the window, it still exhibits the cairo crash assert related to having cached entries in the font map hash table.

Reference: #756

Signed-off-by: Marius Vlad marius.vlad@collabora.com

Merge request reports

Loading