Quoting Diego Biurrun (2015-03-01 19:45:08)
> On Sat, Feb 28, 2015 at 11:17:37AM +0100, Alexandra Hájková wrote:
> > From: alexandra <alexandra@sai>
> > 
> > The old one is result of reverse engeneering and guesswork.
> 
> engIneering
> 
> All engineers should know how to spell that word :)
> 
> > --- a/libavformat/asfdec.c
> > +++ b/libavformat/asfdec.c
> > @@ -39,151 +39,296 @@
> > +static int read_metadata(AVFormatContext *s, const char *title, uint16_t 
> > len,
> > +                         unsigned char *ch, uint16_t max_len)
> >  {
> > +    if (av_dict_set(&s->metadata, title, ch, 0) < 0)
> > +        av_log(s, AV_LOG_WARNING, "av_dict_set failed.\n");
> > +
> > +
> > +    return 0;
> 
> stray double empty line
> 
> I like that there is some error checking for av_dict_set() now, but I would
> suggest erroring out when it fails.  IMNSHO metadata is not a second class
> citizen.  We should not make a decision which errors are important or not
> in the library.  That's for our users to decide, we should not make such
> decisions for them.

Except by erroring out you are making a decision for the caller -- since
reading the header fails, you cannot demuxer the file.

-- 
Anton Khirnov
_______________________________________________
libav-devel mailing list
[email protected]
https://lists.libav.org/mailman/listinfo/libav-devel

Reply via email to