diff mbox series

[FFmpeg-devel,23/23] avformat/matroskaenc: Reindent after previous commit

Message ID 20200117200051.30727-1-andreas.rheinhardt@gmail.com
State Accepted
Headers show
Series Matroska muxer patches
Related show

Checks

Context Check Description
andriy/ffmpeg-patchwork pending
andriy/ffmpeg-patchwork success Applied patch
andriy/ffmpeg-patchwork success Configure finished
andriy/ffmpeg-patchwork success Make finished
andriy/ffmpeg-patchwork success Make fate finished

Commit Message

Andreas Rheinhardt Jan. 17, 2020, 8 p.m. UTC
Also remove { } after an if if there is only one statement inside { }.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
 libavformat/matroskaenc.c | 29 ++++++++++++++---------------
 1 file changed, 14 insertions(+), 15 deletions(-)
diff mbox series

Patch

diff --git a/libavformat/matroskaenc.c b/libavformat/matroskaenc.c
index 93f01da930..83ed43ab77 100644
--- a/libavformat/matroskaenc.c
+++ b/libavformat/matroskaenc.c
@@ -1285,22 +1285,21 @@  static int mkv_write_track(AVFormatContext *s, MatroskaMuxContext *mkv,
 
     case AVMEDIA_TYPE_AUDIO:
         if (par->initial_padding && par->codec_id == AV_CODEC_ID_OPUS) {
-        int64_t codecdelay = av_rescale_q(par->initial_padding,
-                                          (AVRational){ 1, 48000 },
-                                          (AVRational){ 1, 1000000000 });
-        if (codecdelay < 0) {
-            av_log(s, AV_LOG_ERROR, "Initial padding is invalid\n");
-            return AVERROR(EINVAL);
-        }
-//         mkv->tracks[i].ts_offset = av_rescale_q(par->initial_padding,
-//                                                 (AVRational){ 1, par->sample_rate },
-//                                                 st->time_base);
+            int64_t codecdelay = av_rescale_q(par->initial_padding,
+                                              (AVRational){ 1, 48000 },
+                                              (AVRational){ 1, 1000000000 });
+            if (codecdelay < 0) {
+                av_log(s, AV_LOG_ERROR, "Initial padding is invalid\n");
+                return AVERROR(EINVAL);
+            }
+//            mkv->tracks[i].ts_offset = av_rescale_q(par->initial_padding,
+//                                                    (AVRational){ 1, par->sample_rate },
+//                                                    st->time_base);
 
-        put_ebml_uint(pb, MATROSKA_ID_CODECDELAY, codecdelay);
-    }
-    if (par->codec_id == AV_CODEC_ID_OPUS) {
-        put_ebml_uint(pb, MATROSKA_ID_SEEKPREROLL, OPUS_SEEK_PREROLL);
-    }
+            put_ebml_uint(pb, MATROSKA_ID_CODECDELAY, codecdelay);
+        }
+        if (par->codec_id == AV_CODEC_ID_OPUS)
+            put_ebml_uint(pb, MATROSKA_ID_SEEKPREROLL, OPUS_SEEK_PREROLL);
 
         put_ebml_uint(pb, MATROSKA_ID_TRACKTYPE, MATROSKA_TRACK_TYPE_AUDIO);