aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/mpeg.c
diff options
context:
space:
mode:
authorClément Bœsch <u@pkh.me>2013-10-04 09:25:08 +0000
committerClément Bœsch <clement@stupeflix.com>2013-10-04 09:25:11 +0000
commitd4dc673455164c5c15092abd163ec808be24f694 (patch)
treee59ec2c2fcc7080123f6366ba7d914badf65feb6 /libavformat/mpeg.c
parentdbfe61100bd7c9c9afb34b35a7e2cbf28807062d (diff)
downloadffmpeg-d4dc673455164c5c15092abd163ec808be24f694.tar.gz
avformat/vobsub: raise packet even if apparently incomplete.
This restore the latest packet which was dropped from the FATE test in dbfe61100.
Diffstat (limited to 'libavformat/mpeg.c')
-rw-r--r--libavformat/mpeg.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/libavformat/mpeg.c b/libavformat/mpeg.c
index f59cc58ce4..64c5a4ff2a 100644
--- a/libavformat/mpeg.c
+++ b/libavformat/mpeg.c
@@ -849,8 +849,11 @@ static int vobsub_read_packet(AVFormatContext *s, AVPacket *pkt)
int pkt_size;
ret = mpegps_read_pes_header(vobsub->sub_ctx, NULL, &startcode, &pts, &dts);
- if (ret < 0)
+ if (ret < 0) {
+ if (pkt->size) // raise packet even if incomplete
+ break;
FAIL(ret);
+ }
to_read = ret & 0xffff;
new_pos = avio_tell(pb);
pkt_size = ret + (new_pos - old_pos);