diff --git a/libavformat/mov.c b/libavformat/mov.c
index 83dcdf0ec7b83f58b9ab5a6171190cab55e44b1c..cbd0f760eee32f4818164a61689957d95a114193 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -1509,6 +1509,7 @@ static int mov_read_header(AVFormatContext *s, AVFormatParameters *ap)
         if(!sc->stts_count || !sc->chunk_count || !sc->sample_to_chunk_sz ||
            (!sc->sample_size && !sc->sample_count)){
             av_log(s, AV_LOG_ERROR, "missing mandatory atoms, broken header\n");
+            sc->sample_count = 0; //ignore track
             continue;
         }
         if(!sc->time_rate)