Bug#672706: Bug#672947: fcmatch.c:548: IA__FcFontMatch: Assertion `result != ((void *)0)' failed.

Reimar Döffinger Reimar.Doeffinger at gmx.de
Wed May 16 21:34:12 UTC 2012


On Wed, May 16, 2012 at 09:04:26PM +0200, Reinhard Tartler wrote:
> On Wed, May 16, 2012 at 1:07 PM, Fabian Greffrath <fabian at greffrath.com> wrote:
> > Am Montag, den 14.05.2012, 23:23 +0200 schrieb Alex Wilk:
> >> mplayer: fcmatch.c:548: IA__FcFontMatch: Assertion `result != ((void *)0)' failed.
> >
> > In line 1163 in file sub/font_load_ft.c of the mplayer2 source code the
> > following code is called:
> >
> >        fc_pattern = FcFontMatch(0, fc_pattern, 0);
> >
> > The third argument passed to FcFontMatch() is the *result pointer, which
> > is 0 in this case. Newer versions of fontconfig seem to include an
> > assertion that this may never be 0, so it fails. Simply passing
> > "&result" instead of 0 (as in line 1153) should solve the problem here.
> >
> > I think the same applies to #672706 reported against mplayer.
> 
> Excellent catch. For the reference, the code in question can be
> inspected in the upstream gitweb here:
> http://cgit.freedesktop.org/fontconfig/tree/src/fcmatch.c?id=2.9.0#n548

Actually the first FcFontMatch in that function is already fixed,
it seems the second one was missed.
I fixed it now too in MPlayer SVN (r34910), plus I added an initialization
of the result variable (r34911) since FcFontMatch still seems to only set
it on error which might result in very strange behaviour if the
code ever is changed to use it.





More information about the pkg-multimedia-maintainers mailing list