rtpdec: Store the previous return value for mpegts when it was -1, too

Originally committed as revision 25403 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Martin Storsjö 2010-10-08 07:28:17 +00:00
parent 243ac3fdaa
commit 45658b7414
1 changed files with 3 additions and 1 deletions

View File

@ -471,8 +471,10 @@ static int rtp_parse_packet_internal(RTPDemuxContext *s, AVPacket *pkt,
if (!st) { if (!st) {
/* specific MPEG2TS demux support */ /* specific MPEG2TS demux support */
ret = ff_mpegts_parse_packet(s->ts, pkt, buf, len); ret = ff_mpegts_parse_packet(s->ts, pkt, buf, len);
if (ret < 0) if (ret < 0) {
s->prev_ret = -1;
return -1; return -1;
}
if (ret < len) { if (ret < len) {
s->read_buf_size = len - ret; s->read_buf_size = len - ret;
memcpy(s->buf, buf + ret, s->read_buf_size); memcpy(s->buf, buf + ret, s->read_buf_size);