]> git.tue.mpg.de Git - paraslash.git/commitdiff
mp4: Remove always true condition in mp4ff_parse_tag().
authorAndre Noll <maan@tuebingen.mpg.de>
Mon, 9 Aug 2021 18:39:05 +0000 (20:39 +0200)
committerAndre Noll <maan@tuebingen.mpg.de>
Mon, 30 May 2022 19:37:35 +0000 (21:37 +0200)
The parentheses are redundant, and "done" can never be true here.

mp4.c

diff --git a/mp4.c b/mp4.c
index fc74327138d8f9a3b4beb2adde0d1232fa9e3958..b2a4795d924d4e8e03fccd7c5b29b8cfa3225b76 100644 (file)
--- a/mp4.c
+++ b/mp4.c
@@ -1003,7 +1003,7 @@ static int32_t mp4ff_parse_tag(mp4ff_t * f, const uint8_t parent_atom_type,
                                done = 1;
                        }
                } else if (parent_atom_type == ATOM_TRACK || parent_atom_type == ATOM_DISC) {
-                       if (!done && (subsize - header_size) >= (sizeof (char) + sizeof (uint8_t) * 3 + sizeof (uint32_t) +     /* version + flags + reserved */
+                       if (subsize - header_size >= (sizeof (char) + sizeof (uint8_t) * 3 + sizeof (uint32_t) +        /* version + flags + reserved */
                                                                 +(parent_atom_type == ATOM_TRACK ? sizeof (uint16_t) : 0)      /* leading uint16_t if ATOM_TRACK */
                                                                 +sizeof (uint16_t)     /* track / disc */
                                                                 +sizeof (uint16_t))    /* totaltracks / totaldiscs */) {