[cairo] memory leak in _cairo_pattern_create_solid

Behdad Esfahbod behdad at behdad.org
Tue Oct 16 15:10:49 PDT 2007


On Tue, 2007-10-16 at 13:46 -0700, Carl Worth wrote:
> 
> So what we provide is the ability for the application author to first
> clean up all references, then call cairo_debug_reset_static_data and
> if the cache finds that any objects are still referenced then there's
> definitely a bug somewhere. This seems extremely useful to me. 

This is what fontconfig does too, and it's biting us in firefox3.
Problem is, it's a vicious circle:

  - To find your application leaks, you need to get rid of fontconfig
noise, that is, call FcFini().

  - To call FcFini() successfully, you need to get rid of your
application leaks.

Same with cairo, just that cairo doesn't abuse memory like fontconfig
does, so people have a much easier time finding cairo leaks.

-- 
behdad
http://behdad.org/

"Those who would give up Essential Liberty to purchase a little
 Temporary Safety, deserve neither Liberty nor Safety."
        -- Benjamin Franklin, 1759





More information about the cairo mailing list