]> git.ipfire.org Git - thirdparty/tvheadend.git/commitdiff
Fix division by 0, fixes #5754
authorFlole998 <Flole998@users.noreply.github.com>
Sun, 20 Oct 2019 00:11:39 +0000 (02:11 +0200)
committerJaroslav Kysela <perex@perex.cz>
Sun, 20 Oct 2019 04:26:11 +0000 (06:26 +0200)
src/idnode.c

index d2b305f35f558eb84a1b75f44c4802bf18d1aeb8..357d05992027ac00ee6a142010879178aa161e7a 100644 (file)
@@ -852,7 +852,7 @@ idnode_filter_init
             p->type == PT_TIME) {
           int64_t v = f->u.n.n;
           if (INTEXTRA_IS_SPLIT(p->intextra) && p->intextra != f->u.n.intsplit) {
-            v = (v / MIN(1, f->u.n.intsplit)) * p->intextra;
+            v = (v / MAX(1, f->u.n.intsplit)) * p->intextra;
             f->u.n.n = v;
           }
         }