[vlc-devel] Deadlock in freetype module
Rémi Denis-Courmont
rem at videolan.org
Mon Aug 18 20:02:49 CEST 2008
Le lundi 18 août 2008 20:57:11 Laurent Aimar, vous avez écrit :
> What this mess try to do:
> - it creates a *unique* fontconfig for all instance of freetype.
> - this fontconfig will be created in its own thread on the first freetype
> module creation (it can take a really long times).
> - this fontconfig will be destroyed on the last freetype module release.
> - the freetype module will use the fontconfig as soon as available, but it
> can still work without it (a bit degraded that's all).
My point is, var_AcquireMutex() is meant to create PROCESS-wide locks, for use
with thread-unsafe library calls, especially library init/deinit functions.
The FreeType module is creating one fontconfig instance per LibVLC instance.
which can be more than one per process. Of course, sharing a lock is always
possible, but inefficient at best (the Qt4 vout does this for lack of better
solution).
--
Rémi Denis-Courmont
http://git.remlab.net/cgi-bin/gitweb.cgi?p=vlc-courmisch.git;a=summary
More information about the vlc-devel
mailing list