On Tue, Nov 08, 2016 at 04:34:13PM +0800, Chen Meng wrote: > --- > libavformat/mov.c | 15 +++++++++++---- > 1 file changed, 11 insertions(+), 4 deletions(-) > > diff --git a/libavformat/mov.c b/libavformat/mov.c > index f06de06..388cd1f 100644 > --- a/libavformat/mov.c > +++ b/libavformat/mov.c > @@ -4533,13 +4533,20 @@ static int mov_read_uuid(MOVContext *c, AVIOContext > *pb, MOVAtom atom) > if (!buffer) { > return AVERROR(ENOMEM); > } > - ret = avio_read(pb, buffer, len); > + > + if (c->export_xmp) { > + ret = avio_read(pb, buffer, len); > + if (ret != len) { > + av_free(buffer); > + return AVERROR_INVALIDDATA; > + }
this looses the error code in ret [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Its not that you shouldnt use gotos but rather that you should write readable code and code with gotos often but not always is less readable
signature.asc
Description: Digital signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel