Originally committed as revision 22703 to svn://svn.ffmpeg.org/ffmpeg/trunk
marker = get_le32(pb);
if (url_feof(s->pb))
- return AVERROR(EIO);
+ return AVERROR_EOF;
if (marker != TXD_MARKER && marker != TXD_MARKER2) {
av_log(s, AV_LOG_ERROR, "marker does not match\n");
- return AVERROR(EIO);
+ return AVERROR_INVALIDDATA;
}
switch (id) {
goto next_chunk;
default:
av_log(s, AV_LOG_ERROR, "unknown chunk id %i\n", id);
- return AVERROR(EIO);
+ return AVERROR_INVALIDDATA;
}
ret = av_get_packet(s->pb, pkt, chunk_size);
+ if (ret < 0)
+ return ret;
pkt->stream_index = 0;
- return ret <= 0 ? AVERROR(EIO) : ret;
+ return 0;
}
AVInputFormat txd_demuxer =