diff --git a/libavformat/mpegts.c b/libavformat/mpegts.c index 5f53f77d89..a5cb17ac16 100644 --- a/libavformat/mpegts.c +++ b/libavformat/mpegts.c @@ -465,6 +465,7 @@ static void write_section_data(MpegTSContext *ts, MpegTSFilter *tss1, offset += tss->section_h_size; tss->section_h_size = -1; } else { + tss->section_h_size = -1; tss->end_of_section_reached = 0; break; }