[Ffmpeg-devel] Re: Re: [PATCH] file length handling

Ronald S. Bultje rbultje
Wed Dec 20 14:43:23 CET 2006


Hi Michael,

On Tue, 2006-12-19, Michael Niedermayer wrote:
> On Mon, Dec 18, 2006 at 09:11:55PM -0500, Ronald S. Bultje wrote:
> > On Mon, 2006-12-18, Michael Niedermayer wrote:
> > > On Mon, Dec 18, 2006 at 08:55:43PM +0100, Ronald S. Bultje wrote:
> > > > On Mon, 18 Dec 2006, Michael Niedermayer wrote:
> > > > > On Mon, Dec 18, 2006 at 09:20:49AM -0500, Ronald S. Bultje wrote:
> > > > > > -#define LIBAVFORMAT_VERSION_INT ((51<<16)+(6<<8)+0)
> > > > > > -#define LIBAVFORMAT_VERSION     51.6.0
> > > > > > +#define LIBAVFORMAT_VERSION_INT ((52<<16)+(0<<8)+0)
> > > > > > +#define LIBAVFORMAT_VERSION     52.0.0
> > > > > >  #define LIBAVFORMAT_BUILD       LIBAVFORMAT_VERSION_INT
> > [..]
> > > external or not how does adding a field to the end break anyting?
> > > no external code should depend on any struct size if it does its
> > > broken IMHO
> > 
> > I don't add it to the end. URLContext has a char filename[1] at the end,
> > which is used for dynamic sizing of the struct.
> 
> you are right :(
> i (and i belive many of our users too) would prefer if compatibility wouldnt
> be broken, its broken often enough anyway
> 
> so either we put the addition of filesize under 
> #if LIBAVFORMAT_VERSION_INT > ...

This sounds relatively easy to me, so let's do this. I've attached new
patches for both file length handling and http seeking that use this.
I'll send in a cleanup to remove the #ifs after the AVFrac patch is in.

> and independant of all that it would be nice if char filename[1] could be
> changed to char *filename in the next major version bump so this issue 
> wont happen again

I agree.

Cheers,
Ronald
-------------- next part --------------
A non-text attachment was scrubbed...
Name: urictx-len.patch
Type: text/x-patch
Size: 7435 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20061220/d4ea98b1/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: http-seek.patch
Type: text/x-patch
Size: 7368 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20061220/d4ea98b1/attachment-0001.bin>



More information about the ffmpeg-devel mailing list