[FFmpeg-devel] [PATCH] File concat protocol

Wolfram Gloger wmglo
Wed Jul 4 15:08:43 CEST 2007


Hi,

> From: Michael Niedermayer <michaelni at gmx.at>
> > +    uinfo =3D (struct urlconcat_info *) h->priv_data;
> 
> unneeded cast

All removed.

> > +        strncpy(fn, filename, len);
> 
> shouldnt av_strlcpy() be used here?

Changed.

> > +            return AVERROR_NOMEM;
> 
> please use AVERROR() AVERROR_* is deprecated

Ok, but could someone please add a note to this effect to avcodec.h?
I could find this nowhere, and AVERROR_* is used quite extensively.

> i think a single array of a struct of url_desc + size would be simpler

Ok.

> also the uc and size (temporary) variables are unneeded

Disagree, that would make a leak-free open() very messy.

> and i think the seeking code should be simpler if instead of storing the
> sizes of all urls the sum of sizes of the previous urls would be stored
> (so that url_sizes[i] is the size of url 0 to i)
> though if its not simpler then just disregard this comment

I don't think is becomes simpler because of the whence==SEEK_END
case (added just for you :), so I didn't change this.

Regards,
Wolfram.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/octet-stream
Size: 5945 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20070704/f0c4fbfb/attachment.obj>



More information about the ffmpeg-devel mailing list