diff mbox series

[FFmpeg-devel,2/2] avformat/utils: reindent after remove if()

Message ID tencent_F27E52AFA638E5C009B6A468D200A969FE0A@qq.com
State New
Headers show
Series [FFmpeg-devel,1/2] avformat/utils: remove always true if()
Related show

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

zhilizhao July 28, 2020, 5:02 p.m. UTC
---
 libavformat/utils.c | 16 ++++++++--------
 1 file changed, 8 insertions(+), 8 deletions(-)
diff mbox series

Patch

diff --git a/libavformat/utils.c b/libavformat/utils.c
index af1cca0c7d..88b69c6036 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -2583,14 +2583,14 @@  int avformat_seek_file(AVFormatContext *s, int stream_index, int64_t min_ts,
 
     // Fall back on old API if new is not implemented but old is.
     // Note the old API has somewhat different semantics.
-        dir = (ts - (uint64_t)min_ts > (uint64_t)max_ts - ts ? AVSEEK_FLAG_BACKWARD : 0);
-        ret = av_seek_frame(s, stream_index, ts, flags | dir);
-        if (ret<0 && ts != min_ts && max_ts != ts) {
-            ret = av_seek_frame(s, stream_index, dir ? max_ts : min_ts, flags | dir);
-            if (ret >= 0)
-                ret = av_seek_frame(s, stream_index, ts, flags | (dir^AVSEEK_FLAG_BACKWARD));
-        }
-        return ret;
+    dir = (ts - (uint64_t)min_ts > (uint64_t)max_ts - ts ? AVSEEK_FLAG_BACKWARD : 0);
+    ret = av_seek_frame(s, stream_index, ts, flags | dir);
+    if (ret<0 && ts != min_ts && max_ts != ts) {
+        ret = av_seek_frame(s, stream_index, dir ? max_ts : min_ts, flags | dir);
+        if (ret >= 0)
+            ret = av_seek_frame(s, stream_index, ts, flags | (dir^AVSEEK_FLAG_BACKWARD));
+    }
+    return ret;
 }
 
 int avformat_flush(AVFormatContext *s)