[MPlayer-dev-eng] Recent regression in FreeMediaType

Vladimir Voroshilov voroshil at gmail.com
Wed Mar 14 04:43:55 CET 2007


2007/3/14, Alan Nisota <alannisota at gmail.com>:
>
> The changes to how AM_MEDIA_TYPE is handled about 2 weeks ago seems to
> be a bit broken.
> Specifically, in FreeMediaType, this code:
>     if (pMediaType->pUnk)
>     {
>         pMediaType->pUnk->vt->Release(pMediaType->pUnk);
>         pMediaType->pUnk = NULL;
>     }
> (well the 'Release') causes a segfault with CoreAVC (gdb reports
> pUnk->vt as inaccessible memory).  I believe this data has already been
> released (but pUnk not zeroed) by the time this gets called
> (MemAllocator_Decommit) though I haven't dug into it much.
> All I know so far is it didn't used to segfault on termination before
> the patch was applied.
>
> I'll try to collect more info, and I realize that as CoreAVC isn't a
> supported codec, I'm on my own, but I figured I'd report it nonetheless.


Perhaps, trouble is in win32.c's expMoCopyMediaType,expMoFreeMediaType and
others. They are neither clears pUnk in Free nor copyes it in Copy.
Try to add "dest->pUnk=0" into expMoFreeMediaType and check if this will
help.

-- 
Regards,
Vladimir Voroshilov     mailto:voroshil at gmail.com
JID: voroshil at jabber.ru
ICQ: 95587719



More information about the MPlayer-dev-eng mailing list