memset(buf, fill_char, size);
}
-static void flush_encoders(int ist_index, OutputStream *ost_table, int nb_ostreams)
+static void flush_encoders(OutputStream *ost_table, int nb_ostreams)
{
int i, ret;
AVCodecContext *enc = ost->st->codec;
AVFormatContext *os = output_files[ost->file_index].ctx;
- if (ost->source_index != ist_index || !ost->encoding_needed)
+ if (!ost->encoding_needed)
continue;
if (ost->st->codec->codec_type == AVMEDIA_TYPE_AUDIO && enc->frame_size <=1)
}
}
discard_packet:
- if (pkt == NULL) {
- /* EOF handling */
- flush_encoders(ist_index, ost_table, nb_ostreams);
- }
return 0;
}
output_packet(ist, i, output_streams, nb_output_streams, NULL);
}
}
+ flush_encoders(output_streams, nb_output_streams);
term_exit();