[FFmpeg-devel] Fwd: [PATCH] Psygnosis YOP demuxer
Michael Niedermayer
michaelni
Sun Dec 27 12:01:37 CET 2009
On Sun, Dec 27, 2009 at 12:52:33PM +0530, Mohamed Naufal wrote:
> 2009/12/27 Michael Niedermayer <michaelni at gmx.at>
>
> > On Sat, Dec 26, 2009 at 11:22:15PM +0530, Mohamed Naufal wrote:
> > > 2009/12/26 Diego Biurrun <diego at biurrun.de>
> > [...]
> > > +static int yop_probe(AVProbeData *probe_packet)
> > > +{
> > > + if (AV_RB16(probe_packet->buf) == AV_RB16("YO") &&
> > > + probe_packet->buf[6] && probe_packet->buf[7] &&
> > > + !(AV_RL16(probe_packet->buf + 8) & 1) &&
> > !(AV_RL16(probe_packet->buf + 10) & 1))
> > > + return AVPROBE_SCORE_MAX / 2 + 1;
> >
> > does this pass probetest?
> >
> >
>
> It does. Were you suggesting returning a higher score?
that might make sense
>
> [...]
>
>
> > > +AVInputFormat yop_demuxer = {
> > > + "yop",
> > > + NULL_IF_CONFIG_SMALL("Psygnosis YOP Format"),
> > > + sizeof(YopDecContext),
> > > + yop_probe,
> > > + yop_read_header,
> > > + yop_read_packet,
> > > + .extensions = "yop",
> >
> > missing code to free packets
> >
>
>
> Freeing both sound & video packets in read_close() results in a double free
> when read_packet() fails and packets are freed in it. So can I move all
> free_packet() calls to read_close() and use flags for selective freeing?
One should not keep duplicated pointers to freed resources around
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
While the State exists there can be no freedom; when there is freedom there
will be no State. -- Vladimir Lenin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20091227/7ed9ebba/attachment.pgp>
More information about the ffmpeg-devel
mailing list