[FFmpeg-cvslog] fftools/ffmpeg_mux: reindent

Anton Khirnov git at videolan.org
Sat Jul 23 13:07:42 EEST 2022


ffmpeg | branch: master | Anton Khirnov <anton at khirnov.net> | Fri Jun 10 12:55:05 2022 +0200| [919638ff5c99e33d91974506b19d42dcee04690b] | committer: Anton Khirnov

fftools/ffmpeg_mux: reindent

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=919638ff5c99e33d91974506b19d42dcee04690b
---

 fftools/ffmpeg_mux.c | 42 +++++++++++++++++++++---------------------
 1 file changed, 21 insertions(+), 21 deletions(-)

diff --git a/fftools/ffmpeg_mux.c b/fftools/ffmpeg_mux.c
index 453ccac912..641bdb98b0 100644
--- a/fftools/ffmpeg_mux.c
+++ b/fftools/ffmpeg_mux.c
@@ -98,16 +98,16 @@ static int queue_packet(OutputFile *of, OutputStream *ost, AVPacket *pkt)
     }
 
     if (pkt) {
-    ret = av_packet_make_refcounted(pkt);
-    if (ret < 0)
-        return ret;
+        ret = av_packet_make_refcounted(pkt);
+        if (ret < 0)
+            return ret;
 
-    tmp_pkt = av_packet_alloc();
-    if (!tmp_pkt)
-        return AVERROR(ENOMEM);
+        tmp_pkt = av_packet_alloc();
+        if (!tmp_pkt)
+            return AVERROR(ENOMEM);
 
-    av_packet_move_ref(tmp_pkt, pkt);
-    ms->muxing_queue_data_size += tmp_pkt->size;
+        av_packet_move_ref(tmp_pkt, pkt);
+        ms->muxing_queue_data_size += tmp_pkt->size;
     }
     av_fifo_write(ms->muxing_queue, &tmp_pkt, 1);
 
@@ -236,20 +236,20 @@ void of_submit_packet(OutputFile *of, AVPacket *pkt, OutputStream *ost)
     int ret;
 
     if (pkt) {
-    /*
-     * Audio encoders may split the packets --  #frames in != #packets out.
-     * But there is no reordering, so we can limit the number of output packets
-     * by simply dropping them here.
-     * Counting encoded video frames needs to be done separately because of
-     * reordering, see do_video_out().
-     */
-    if (!(st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO && ost->encoding_needed)) {
-        if (ost->frame_number >= ost->max_frames) {
-            av_packet_unref(pkt);
-            return;
+        /*
+         * Audio encoders may split the packets --  #frames in != #packets out.
+         * But there is no reordering, so we can limit the number of output packets
+         * by simply dropping them here.
+         * Counting encoded video frames needs to be done separately because of
+         * reordering, see do_video_out().
+         */
+        if (!(st->codecpar->codec_type == AVMEDIA_TYPE_VIDEO && ost->encoding_needed)) {
+            if (ost->frame_number >= ost->max_frames) {
+                av_packet_unref(pkt);
+                return;
+            }
+            ost->frame_number++;
         }
-        ost->frame_number++;
-    }
     }
 
     if (of->mux->header_written) {



More information about the ffmpeg-cvslog mailing list