summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libavformat/gdv.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libavformat/gdv.c b/libavformat/gdv.c
index a69c349cab..3ead383892 100644
--- a/libavformat/gdv.c
+++ b/libavformat/gdv.c
@@ -86,6 +86,9 @@ static int gdv_read_header(AVFormatContext *ctx)
vst->nb_frames = avio_rl16(pb);
fps = avio_rl16(pb);
+ if (!fps)
+ return AVERROR_INVALIDDATA;
+
snd_flags = avio_rl16(pb);
if (snd_flags & 1) {
ast = avformat_new_stream(ctx, 0);