aboutsummaryrefslogtreecommitdiffstats
path: root/libavformat/apc.c
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2012-04-30 22:58:27 +0200
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2012-05-01 23:20:52 +0200
commit7effbee66cf457c62f795d9b9ed3a1110b364b89 (patch)
treea406f659aff1b694e66774acb77ec856024d81d8 /libavformat/apc.c
parent75f847aa6b1bc88733e59d680809f614977b4c07 (diff)
downloadffmpeg-7effbee66cf457c62f795d9b9ed3a1110b364b89.tar.gz
Mark truncated packets as corrupt in av_get_packet.
Manually remove that flag again for formats that read an arbitrary amount of data and thus truncation is not an error. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Diffstat (limited to 'libavformat/apc.c')
-rw-r--r--libavformat/apc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavformat/apc.c b/libavformat/apc.c
index 389eba7b0a..2e160ccab5 100644
--- a/libavformat/apc.c
+++ b/libavformat/apc.c
@@ -76,6 +76,7 @@ static int apc_read_packet(AVFormatContext *s, AVPacket *pkt)
{
if (av_get_packet(s->pb, pkt, MAX_READ_SIZE) <= 0)
return AVERROR(EIO);
+ pkt->flags &= ~AV_PKT_FLAG_CORRUPT;
pkt->stream_index = 0;
return 0;
}