diff mbox series

[FFmpeg-devel,08/11] lavc/jpeg2000: Reindent

Message ID da61d93395b39a91b19d4a922df039e5da2ce078.camel@haerdin.se
State New
Headers show
Series [FFmpeg-devel,01/11] lavc/jpeg2000dec: Finer granularity threading | expand

Checks

Context Check Description
andriy/configure_x86 warning Failed to apply patch

Commit Message

Tomas Härdin Sept. 28, 2022, 10:07 a.m. UTC

diff mbox series

Patch

From 2e915fbbd481c1d202c0ec058842cfc9f9593871 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Tomas=20H=C3=A4rdin?= <git@haerdin.se>
Date: Tue, 14 Jun 2022 11:23:08 +0200
Subject: [PATCH 08/11] lavc/jpeg2000: Reindent

---
 libavcodec/jpeg2000.c | 44 +++++++++++++++++++++----------------------
 1 file changed, 22 insertions(+), 22 deletions(-)

diff --git a/libavcodec/jpeg2000.c b/libavcodec/jpeg2000.c
index 203782502c..2574c2b97e 100644
--- a/libavcodec/jpeg2000.c
+++ b/libavcodec/jpeg2000.c
@@ -94,34 +94,34 @@  static int ff_jpeg2000_tag_tree_init(Jpeg2000TgtNode **old, unsigned int *size,
         } else
             return AVERROR(ENOMEM);
     } else {
-    tt_size = tag_tree_size(w, h);
+        tt_size = tag_tree_size(w, h);
 
-    if (av_size_mult(tt_size, sizeof(*t), &prod))
-        return AVERROR(ENOMEM);
+        if (av_size_mult(tt_size, sizeof(*t), &prod))
+            return AVERROR(ENOMEM);
 
-    av_fast_malloc(old, size, prod);
-    if (!*old)
-        return AVERROR(ENOMEM);
-    t = *old;
-    memset(*old, 0, prod);
+        av_fast_malloc(old, size, prod);
+        if (!*old)
+            return AVERROR(ENOMEM);
+        t = *old;
+        memset(*old, 0, prod);
 
-    while (w > 1 || h > 1) {
-        int i, j;
-        pw = w;
-        ph = h;
+        while (w > 1 || h > 1) {
+            int i, j;
+            pw = w;
+            ph = h;
 
-        w  = (w + 1) >> 1;
-        h  = (h + 1) >> 1;
-        ofs += pw * ph;
+            w  = (w + 1) >> 1;
+            h  = (h + 1) >> 1;
+            ofs += pw * ph;
 
-        for (i = 0; i < ph; i++)
-            for (j = 0; j < pw; j++)
-                t[i * pw + j].parent = (i >> 1) * w + (j >> 1) + ofs;
+            for (i = 0; i < ph; i++)
+                for (j = 0; j < pw; j++)
+                    t[i * pw + j].parent = (i >> 1) * w + (j >> 1) + ofs;
 
-        t += pw * ph;
-    }
-    t[0].parent = -1;
-    return 0;
+            t += pw * ph;
+        }
+        t[0].parent = -1;
+        return 0;
     }
 }
 
-- 
2.30.2