Mercurial > libavformat.hg
changeset 5897:d7f41380f52c libavformat
eacdata: fix a memleak, return partial packets and use proper return values.
author | reimar |
---|---|
date | Sat, 27 Mar 2010 19:09:46 +0000 |
parents | 395592984ef0 |
children | cda7add41fbb |
files | eacdata.c |
diffstat | 1 files changed, 4 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/eacdata.c Fri Mar 26 16:04:38 2010 +0000 +++ b/eacdata.c Sat Mar 27 19:09:46 2010 +0000 @@ -83,10 +83,11 @@ CdataDemuxContext *cdata = s->priv_data; int packet_size = 76*cdata->channels; - if (av_get_packet(s->pb, pkt, packet_size) != packet_size) - return AVERROR(EIO); + int ret = av_get_packet(s->pb, pkt, packet_size); + if (ret < 0) + return ret; pkt->pts = cdata->audio_pts++; - return 1; + return 0; } AVInputFormat ea_cdata_demuxer = {